Keeping a option,select drop down list open on refresh / postback

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • crazychrisy54@hotmail.com

    Keeping a option,select drop down list open on refresh / postback

    Hi there

    I have a option, select drop down list which a user can open. My page
    however refreshes very frequently and when this occurs the selected
    drop down list will pop back up. The user then has to open the drop
    down list again.

    I just wondered if there was a way using javascript to firstly detect
    if the user has selected the drop down list and if so, on refresh to
    set that drop down list to stay dropped down?

    I hope that makes sense, if it doesn't please let me know!
    Thanks for your help
    Chris
  • Laser Lips

    #2
    Re: Keeping a option,select drop down list open on refresh / postback

    Cris, how is the page refreshing?

    If the user is refreshing it by presing the refresh button, or the
    page is refreshing itself using meta tags, then there is no way to
    pass any state information to the page and you can not do it.
    HOWEVER, if the page is using JavaScript to refresh, then you can load
    the page instead of refreshing it and send it the value of the
    currently selected dropdown, and reset the dropdown to that state when
    the page reloads.

    How is your page setup, is it just one frame?

    Graham

    Comment

    • crazychrisy54@hotmail.com

      #3
      Re: Keeping a option,select drop down list open on refresh / postback

      On May 9, 1:23 pm, Laser Lips <loudsphi...@gm ail.comwrote:
      Cris, how is the page refreshing?
      >
      If the user is refreshing it by presing the refresh button, or the
      page is refreshing itself using meta tags, then there is no way to
      pass any state information to the page and you can not do it.
      HOWEVER, if the page is using JavaScript to refresh, then you can load
      the page instead of refreshing it and send it the value of the
      currently selected dropdown, and reset the dropdown to that state when
      the page reloads.
      >
      How is your page setup, is it just one frame?
      >
      Graham
      Hi Graham,

      The page uses just one frame and the page refreshes automatically
      using a meta tag. I was thinking there might be a way using java
      script which detects when a user has clicked the dropped down list and
      if so set a cookie saying the user has currently selected that drop
      down list. Then when the page is refreshed, you could see if that
      cookie is set and if so onload set the drop down list to be displayed?
      I don't know if I am thinking along the right lines though.

      Thanks
      Chris

      Comment

      Working...