Infolink

 

Search This Blog

Oct 14, 2012

Spell as you Type plug-in

Full clientside spell checker for IE 6.0+ users that underlines misspellt words as you type into a textbox or textarea. Right click to see a list of suggested corrections.

Browsers such as Firefox and Chrome have spell as you type built in, this plugin will not have any effect in other browsers.

Use the dictionary supplied or create you own (plain text file, one word per line) using the dictionary builder application. The dictionaries supplied are over 500k each, so enable caching (and compression if available) on the server.

Usage:

Include the jquery.spellayt.js script and the jquery.spellayt.css stylesheet in your page, and place the spellayt.gif image and dictionary.txt file in a visible folder. Check the jquery.spellayt.css file so that you have the correct path to the image file relative to the stylesheet. 


Version 1.3 has major performance improvements and minor bug fixes. You must replace the dictionary used from previous versions. Custom dictionaries must be in alphabetical order.

Examples:

Enable spell as you type for an element named txtTextarea

$(document).ready(function() {
    $('#txtTextarea').spellayt();
})

Spell check and highlight a textarea input:

$('#txtTextarea').each(function(input) {
    $.fn.spellayt.checkSpelling(this);
});
More examples are available at http://www.opencomponents.com/spellayt/demo/.

1 comment:

Related Posts Plugin for WordPress, Blogger...