Grow your CSS skills. Land your dream job.

[Solved] Can I stop browsers suggesting how to fill an input field?

  • # June 11, 2010 at 6:41 am

    HI,
    I have an input field that will be in regular use on my web app but browsers, especially firefox, keep suggesting content to fill the field based on previous input. I’m sure you know what I’m talking about. You know, when I type an "a" it makes a drop down list of previous inputs with an a "a" in it.

    Is there a way to disable this function?

    Thanks

    # June 12, 2010 at 4:40 am

    I don’t know why this is in the ‘JavaScript Help & Troubleshooting’ category.
    http://www.google.co.za/search?source=ig&hl=en&rlz=1G1GGLQ_ENZA377&=&q=disable+firefox+autocomplete&btnG=Google+Search

    # June 12, 2010 at 1:53 pm

    Cheers, but not quite what I’m lookng for. I need something like an attribute to put in the input field to stop it for all visitors.

    I figured that it might be a javascript fix, rather than css or php, and that the fact that there is no normal HTML sub-forum.

    # June 12, 2010 at 4:29 pm

    Why do you want to do this? I don’t think people generally like it when websites interfere with their browser

    # October 4, 2010 at 7:30 am

    Responses like this really frustrate me.
    Matt I have the same requirement as you and would really appreciate any suggestions from someone who has a definitive answer.

    Jamy_za – Think outside your own box – “People generally like” – The web is all about purpose, in my case and I’m sure in Matt’s “WEB APP”, people generally wouldn’t like – hence the original post.

    # October 4, 2010 at 8:04 am

    @nakedweb I’m here to help people. If @mattvot had replied and gave me a fair reason why he wanted it removed, I would then make a plan to either look deeper into it or find a work around – Otherwise I might be wasting my time by looking into something when there is no problem.

    # October 4, 2010 at 11:54 am

    @jamy_za I’m not trying to start a row but the assumption could be that when a request comes from an intelligent sounding person that they do have good reason for wanting it rather than the opposite – thats all.

    Not having a go at you at all just forums are full of non answers and it frustrates me!

    # October 4, 2010 at 2:17 pm

    @nakedweb I’ve found an interesting page. It says:

    At this time, there is no known workaround to disable the native browser autocomplete attribute. Therefore, the native suggestion box may be redundantly displayed during user interactions with the AutoComplete control.

    So it seems as if developers aren’t able to control the users’ browsers’ autocomplete option.

    Edit: Lol, @coffeendonut ‘s solution was extremely simple. I guess the Yahoo article was published a while ago.

    # October 4, 2010 at 2:36 pm

    @mattvot well there is on the ‘ input ‘ tag example



    Username:

    you just put ‘ autocomplete=”off” ‘ on the input filed aka tag…

    # October 4, 2010 at 5:42 pm

    That’s great @coffeendonut and works a treat.
    A bit annoying as I had thought about the autocomplete property but wrongly thought it just prevented password completion. Don’t know where I got that idea from…

    Cheers @jamy_za for looking – my users won’t have to be presented with dozens of useless code options when clicking in my text box ;-)

    # October 4, 2010 at 8:25 pm

    @nakedweb

    i just tried that on the input tag but works to on the form tag…etc



    Username:
    Password:


    # October 7, 2010 at 6:57 am

    @coffeendonut

    Good to know – Cheers again

    # July 17, 2012 at 10:56 pm

    Thanks a bunch for this!

    Just to put it out there, my situation is that one of the features of my web app my own auto complete box which was interfering with this one.

Viewing 13 posts - 1 through 13 (of 13 total)

You must be logged in to reply to this topic.

*May or may not contain any actual "CSS" or "Tricks".