Strange drop down box behavior

hey guys,

I got a very strange behavior of drop down box and tried to fix a lot but couldn’t. So, I am posting here now.

I have a list of options in drop down and also have set a selected option there.
when i select any other option and refresh the page (not submit form) it preserves my selected option currently in drop down. whether it should selected that option in which i have attribute the selected. very annoying

 <select name="select2" id="select2">
      <option value="1">1</option>
      <option value="2">2</option>
      <option value="3" selected="selected">3</option>
      <option value="4">4</option>
      <option value="5">5</option>
    </select>

It is probably supposed to do that (I have to assume you are just hitting F5) rather than SHIFT+F5/RELOAD which in Firefox will reset the form but doesn’t seem to do in some other browsers. It’s a User Agent thing rather than your HTML. Although technically it is recommended the select be the choice displayed as default on a load.

I am using the browser button of FF for refresh.
but how i should convince to my client. This behavior is just in FF not other browsers.

You simply tell them plain HTML is incapable of “memorising things” and that is what the browser does/chooses.

Tell them the truth or just show them an example by using both methods, i.e. the plain ‘Reload’ F5 or the; ‘Reload (override cache)’, i.e. CTRL+F5 or CTRL+SHIFT+R

Else tell them “I, said so…” that will make them tremble in there boots! :wink: