ADVERTISEMENTS

How to remove spell checking from Textarea and Input box in HTML forms

Spell check is not a enabled feature of HTML. It's a default behaviour of web browsers like chrome & firefox. Whenever we type incorrect word inside input and textarea, misseplled word will get highlighted with red underline.

Sometimes, we build form for collecting data with any spell or grammer check. So, HTML has provided a attribute i.e. spellcheck for overwriting default feature of web browsers. We just need to set this attribute to false in particulat element i.e. input or textarea. Here you can find out example code snippet of this attribute.

<!DOCTYPE html>
<html lang="en" >
<head>
<title>Remove Spell Checking from HTMl form </title>
</head>
<body>
    <form>
        <p>
            <input name="email" type="text" spellcheck="false">
        </p>
        <p>
            <textarea name="bio" spellcheck="false"></textarea>
        </p>
    </form>
</body>
</html>

 

Tip: You can also disable spell check for all elements of a HTML form with this attribute too. You just need to add this attribute i.e. spellcheck to false in form tag.

Supported Browsers:
  • Internet Explorer
  • Mozilla Firefox
  • Google Chrome
  • Opera
  • Safari

HTML is base requirement for development of webpages. You can learn HTML from our HTML Tutorials and HTML Examples

ADVERTISEMENTS