All TalkersCode Topics

Follow TalkersCode On Social Media

devloprr.com - A Social Media Network for developers Join Now ➔

Add Spell Checker In Your Webpage Using jQuery

Last Updated : Jul 1, 2023

IN - jQuery HTML | Written & Updated By - Pragati

In this tutorial we will show you how to add spell checker in your webpage using jQuery, When you are publishing any content on anywhere whether it is online or offline you have to make sure your content is write and does not contain any spelling mistake because it gives a negative impact of your writing on reader.

You may also like password strength checker using jQuery.

Add Spell Checker In Your Webpage Using jQuery

To Add Spell Checker It Takes Only One Step:-

  1. Make a HTML file and define markup,scripting and styling

Step 1. Make a HTML file and define markup,scripting and styling

We make a HTML file and save it with a name spell.html

<html>
<head>
<script type="text/javascript" src='jquery.js'></script>
<script type="text/javascript" src='JavaScriptSpellCheck/include.js'></script>
<script type="text/javascript">
function checkspell()
{
 $Spelling.SpellCheckInWindow('textarea');
}
</script>
<style>
body
{
 margin:0 auto;
 padding:0px;
 text-align:center;
 width:100%;
 font-family: "Myriad Pro","Helvetica Neue",Helvetica,Arial,Sans-Serif;
 background-color:#CEE3F6;
}
#wrapper
{
 margin:0 auto;
 padding:0px;
 text-align:center;
 width:995px;
}
#text_div
{
 margin-top:20px;
}
#text_div textarea
{ 
 width:500px;
 height:150px; 
 border:none;
 padding:10px;
 font-size:17px;
}
#text_div input[type="button"]
{
 background-color:#0080FF;
 border:none;
 color:white;
 width:200px;
 height:40px;
 border-bottom:4px solid #0174DF;
 border-radius:3px;
}
</style>
</head>
<body>
<div id="wrapper">

<div id="text_div">
<textarea id="textarea" placeholder="Enter Some Text"></textarea>
<br>
<input type="button" onclick="checkspell();" value="CHECK SPELLING">
</div>

</div>
</body>
</html>

We use JavaScriptSpellCheck plugin to add spell check functionality in our webpage.

In this step we create a textarea for user to enter some text to check spell checker plugin and create a button to call checkspell() function which get our text from textarea and open a small window having different buttons for different operations in it to correct spelling mistakes or insert and remove any word from dictionary.

You may also like add jQuery datepicker.

That's all, this is how to add spell checker in your webpage using jQuery.You can customize this code further as per your requirement. And please feel free to give comments on this tutorial.

I hope this tutorial on add jquery spell checker helps you and the steps and method mentioned above are easy to follow and implement.

Author Image About Pragati

Experienced coding content writer who enjoys breaking down complex concepts in programming languages like Java, Python, C, and C++. Over three years of experience producing interesting and relevant content for a variety of entities. Committed to providing concise and easy-to-understand articles that assist readers in easily understanding technology and industry trends in the world of coding and software development.

Follow Pragati On Linkedin 🡪