You say that when they back up, the results are "empty". Do you really mean that the page shows what it would show for the results, but there are no results?
Or do you mean that they get an error from the browser, and they have to reload the page? and THEN then do see the results?
If it's the second, then this is not a CFSEARCH problem, nor even a CF problem. It's a generic http problem (it would happen in any CF code and indeed any application server).
Why do I say that? I see that your code checks that there has been a form submission, and only does the search if it is. The problem is that according to the http spec, the results of a form post are NOT cached on the client (the browser), so when they hit the back button (to go "back" to that results page), the browser says the results can't be shown.
But if they refresh it then, the browser prompts if they want to re-send the form fields, and if they do, then you DO see the results. Is that what you are seeing?
Or do you mean it's the first problem above? If so, I would be surprised (given my explanation of the generic second problem).
Thanks for the answer Charlie,
First problem above, it don't ask to resend the form submission it only don't show any result, and even if I do a refresh manually it don't repost my form submission...
I did a work around, not the best solution but it work .... I store the form value in a session for 15 minutes and when the customer click back if my form data is not there and my session is still alive I just do the search with the value in the session ...
<cfsearch name="searchResults" collection=" sextantFR" criteria="#form.recherche#">
<cfsearch name="searchResults" collection=" sextantFR" criteria="#session.recherchecache#">
I have to say, that problem is with Google Chrome and IE,
Firefox show the previous page without asking anything
Safari ask to re-submit and show the result.
Interesting, and curious. Anyway, glad you got a solution.