How to disable copy paste and autocomplete for an HTML textbox

<INPUT size=12 name=”FundsTransferTo” maxlength=12 onCopy=”return false” onDrag=”return false” onDrop=”return false” onPaste=”return false” autocomplete=off>

10 Comments »

  1. Anil Kumar said

    On Mozilla its not workingn :(

  2. Firos said

    It will work fine in IE. The properties like onDrop, onPaste of html textbox are only for IE. It is better to use some javascript function instead.

  3. It may only work in IE, but that saves me a lot of spam from people who use a contact form to paste some huge block of text to advertise their website. I feel a contact form (as in my case) is for requesting information, not advertising. It was a BIG Help. Thanks.

  4. Veera said

    Indeed, It is a very good one. It will be very helpful if somebody gives browse-free solution

  5. eanirudh said

    its works on IE only, can u provide code which can work on all browser.
    ==================================
    http://eanirudh.wordpress.com
    ==================================

  6. shaik ismail said

    Hi its good i like it.. very very thanks….thanks a lot…………..

  7. Melonheadj44 said

    It works in Firefox and IE and Chrome…

    • ragini said

      noops its nt working vid chrome n mozilla bt only vid ie, can anybdy give me solution for chrome n mozilla????

  8. SeanG said

    Google uses autocomplete=”off” on their main search field.

  9. santosh said

    onDrag, onDrop not working in Mozilla

RSS feed for comments on this post · TrackBack URI

Leave a Comment