Remember data

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • FrEaKmAn
    New Member
    • Aug 2007
    • 46

    Remember data

    Hello

    I'm building a simple search option so my site and I have a problem with remembering the data. For example if user hits the search button, the data is loaded with ajax and he/she goes to the next link showed in loaded data. Now when he/she hits the return button, it goes back to main state, but I want that it returns to state where the search data is showed....

    should I use some tricks, maybe remembering data with cookies or something...
  • acoder
    Recognized Expert MVP
    • Nov 2006
    • 16032

    #2
    Yes, or add history/back button functionality to your Ajax application. See, for example, this link.

    Comment

    • FrEaKmAn
      New Member
      • Aug 2007
      • 46

      #3
      hm, looks interesting, only problem is that it doesn't work with safari... maybe does now after almost 3 years...

      my idea was to use ajax to store data, basically what is users searching, where etc and then this data is reloaded when he/she returns to search page. Only problem is that I don't know how to separate returning to search page and accessing it (it will load last searched data).. any ideas?

      Comment

      • acoder
        Recognized Expert MVP
        • Nov 2006
        • 16032

        #4
        Well, in that case, use cookies. If the cookie is set, reload the search, otherwise keep the default state.

        Comment

        Working...