Reputation: 1129
I am developing a web page that has a textarea. This page required very basic text formatting elements like Bold
,Italic
,Underline
and a SpellChecker
only. So i using CKEditor, I hava added first three but there is a problem with adding SpellChecker
. What should i do with my code to make it right, my code is :
<form>
<p>
<textarea cols="80" id="editor1" name="editor1" rows="10"></textarea>
<script src="//cdn.ckeditor.com/4.5.1/full/ckeditor.js"></script>
<script>
CKEDITOR.replace('editor1', {
toolbar: [
['Bold', 'Italic', 'Underline', '-', 'SpellChecker']
]
});
</script>
</p>
<p>
<input type="submit" value="Submit">
</p>
</form>
My fiddle https://jsfiddle.net/520dzLhp/3/
Upvotes: 0
Views: 81
Reputation: 1191
There is two ways to achieve this target here:
- Native Browser Spell Checker:
According to CKEditor tutorial..
By default, browser native spell check functionality is disabled in the editor.
if you want to activate native spell checker you have to use the config param:
config.disableNativeSpellChecker = false;
- Spell Check As You Type (SCAYT):
Which is a plugin you can download it here, and include it with your CKEditor plugins
- Spell Checking in a Dialog Window:
Another solution (If you don't prefer the browser to send many requests during writing) is to use the plugin WebSpellChecker
which only check your text when you click the spellcheck button and opens a popup with the results and you can download it here
Update After a very long searching and inspecting... try this:
toolbar: [['Bold', 'Italic', 'Underline', '-', 'Scayt']]
or this:
toolbarGroups: [
{ name: 'editing', groups: ['spellchecker' ] },
{ name: 'basicstyles', groups: [ 'basicstyles' ] }
]
Upvotes: 2