Ajax back button problem
CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 7 of 7

Thread: Ajax back button problem

  1. #1
    Join Date
    Dec 2006
    Posts
    21

    Question Ajax back button problem

    Hi friends
    Am working on an ASP.NET project that uses ajax for filling the dropdown lists.Its a search page and user have to select some search criteria.Dropdowns are filled with data using ajax.After a search if user presses back button the dropdowns that are filled in client side is not maintaining the data.
    How can i store the previous state to deal with the back button.?

    Plz help.

  2. #2
    PeejAvery's Avatar
    PeejAvery is offline Super Moderator Power Poster
    Join Date
    May 2002
    Posts
    10,879

    Re: Ajax back button problem

    The back button is completely controlled by the browser. It relies upon what the browser thinks is the correct cache for that page. I don't believe that there is a solution for this.
    If the post was helpful...Rate it! Remember to use [code] or [php] tags.

  3. #3
    Join Date
    Dec 2006
    Posts
    21

    Post Re: Ajax back button problem

    hi

    Ya back button is browser's own thing.we cannot access that.I know that.
    I found something in net.This article uses javascript to override the back button problem.I couldnt understand this fully but i am going through it.They are using IFrames for it.

    www.contentwithstyle.co.uk/articles/38

    There is also a javascript toolkit DOJO which is said to have solved back button problem.

    Those who have problems with back button just go through it.

  4. #4
    Join Date
    Jan 2003
    Location
    7,107 Islands
    Posts
    2,487

    Re: Ajax back button problem

    i thought the window's onload event is fired when you hit the "back" button. have you tried to run your "ajax" there? think it will work.
    Busy

  5. #5
    Join Date
    Dec 2006
    Posts
    21

    Re: Ajax back button problem

    yes the onload event is fired.I need to call the binding functions again to show the previous data in dropdown.

    But i stored all html containing the dropdowns in an hidden field and i am showing it again

  6. #6
    Join Date
    Dec 2007
    Posts
    5

    Re: Ajax back button problem

    do you use one form per page?

  7. #7
    Join Date
    Dec 2006
    Posts
    21

    Re: Ajax back button problem

    Sorry to reply too late..

    Ya am using one form per page.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  


Windows Mobile Development Center


Click Here to Expand Forum to Full Width

This is a CodeGuru survey question.


Featured


HTML5 Development Center