I've created a search page using Views with exposed filters and the basic search module. The search only returns results for a specific node content type 'resource'. A typical use case would be the following:
User goes to search page, types some text into the exposed search terms block, and also selects some options from the exposed filters that are drop-down menus. They click 'search' and their results are returned on the same page. Pretty standard stuff and I have that all working fine.
A user then clicks a link to a resource node of interest to them and goes to that node's profile page. All fine and dandy.
The problem is when they want to go BACK. I went ahead and added a back button with the following code to my node--resource.tpl.php, which works as you'd expect (it bypasses the browser back button and takes user to main search page again):
<input type="button" value="Go Back" onclick="window.history.back()" />
What happens is it displays the search page again, but no longer with the search term they entered OR the exposed filters they selected. I'd like to change that so when they click the 'back' button the search page still shows their search results from before so they don't have to re-select all their options again.
This seems like pretty basic stuff, but I can't figure out how to do it in Drupal. I imagine it involves session cookies somehow...but how to combine this with Views I do not know.
Thanks for your help!