Firefox keeps input value on browser close and reopen -


i using input field store destination value:

<input type="text" id="dest_location" placeholder="enter destination" autocomplete="off"> 

however want clear value on browser reload. after reading found simple way add autocomplete="off" input above.

this works noticed unusual in firefox browser. when enter value input field, close browser , reopen value still saved. after clicking page reload button value cleared.

i wanted know why occurring in firefox browser? tried same open , close browser method on chrome, ie , opera , value cleared before clicking on page reload button. assistance.

you must have enabled saving current tab instance in firefox option

    "when firefox starts": "show windows , tabs last time". 

i've tried similar option on google chrome says

    "on startup":"continue left off".  

but chrome is, stores urls next time reopen browser whereas firefox stores copy of current html too. hence have data pre-filled in textbox. looking solution or workaround this?

if doing

    window.onload = function() { document.getelementbyid('dest_location').value="";//element cleared }; 

should fix things you.


Comments

Popular posts from this blog

get url and add instance to a model with prefilled foreign key :django admin -

css - Make div keyboard-scrollable in jQuery Mobile? -

ruby on rails - Seeing duplicate requests handled with Unicorn -