Possible Duplicate:
How do you disable browser Autocomplete on web form field / input tag?
Hello,
I have a search engine on my website with a function that shows possible results via Ajax. How can I tell the browser that it should not show the content I have searched before in a text field. So when I have a text field and someone is typing in it, there should not be the thing, that usually pops up and shows you the searches, you have allready made before. For example when typing in the search 开发者_如何学Pythonfield of Google the browser doesnt give me suggestions for what I might search. Because if that "field of suggestions" shows up, the user can not see the ajax suggestions of my website anymore.
Thanks for your help!
Well, Google's source code has "<input autocomplete=off >
":
<input autocomplete="off" class=lst type=text name=q
maxlength=2048 value="" title="Search">
document.getElementById('search').setAttribute('autocomplete', 'off');
精彩评论