Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
menu search
person
Welcome To Ask or Share your Answers For Others

Categories

I found a strange issue. Open a simple page in Firefox, the code is simple as below:

<html>
  <body>
    <textarea></textarea>
  </body>
</html>

In Firefox, I type some characters in the textarea. Then I click refresh button of the browser. Surprisingly, after the page refreshed, what I typed is still there in textarea. However, if I just focus on URL bar and press ENTER key, the textarea is clear after refreshing.

I reproduced this in Firefox 3.6.12 in Linux and 3.6.3 in MacOS. And, I have only Firebug extension installed so it should NOT be due to Firefox extension.

Is this a know issue? How to make textarea clear after Refresh button is clicked?

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
309 views
Welcome To Ask or Share your Answers For Others

1 Answer

For textarea only:

<textarea autocomplete="off"></textarea>

For all form fields

<form autocomplete="off">

Preventing Firefox from remembering the input value on refresh with Meta tag


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
...