Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

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

  • This topic is empty.
Viewing 12 posts - 1 through 12 (of 12 total)
  • Author
    Posts
  • #29327
    mattvot
    Member

    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

    #77727
    mattvot
    Member

    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.

    #77696
    jamygolden
    Member

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

    #78734
    nakedweb
    Member

    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.

    #78735
    jamygolden
    Member

    @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.

    #78737
    nakedweb
    Member

    @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!

    #78742
    jamygolden
    Member

    @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.

    #78744
    coffeendonut
    Member

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



    Username:

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

    #78754
    nakedweb
    Member

    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 ;-)

    #78760
    coffeendonut
    Member

    @nakedweb

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



    Username:
    Password:


    #78541
    nakedweb
    Member

    @coffeendonut

    Good to know – Cheers again

    #106291

    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 12 posts - 1 through 12 (of 12 total)
  • The forum ‘JavaScript’ is closed to new topics and replies.