The following is also using HTMLArea 3 with the SpellChecker plugin loaded (from
CVS).
In your theme header.thtml add the following with in the head section.
Text Formatted Code
<script type="text/javascript">
_editor_url = "/htmlarea/";
_editor_lang = "en";
</script>
<script type="text/javascript" src="/htmlarea/htmlarea.js"></script>
Then, for each editor that you want to replace, open the appropriate .thtml, such as /path/to/geeklog/layout/YOURLAYOUT/submit/submitstory.thtml, submitlink.thtml, commentform.thtml and add the following at the top of the file
Text Formatted Code
<script type="text/javascript">
HTMLArea.loadPlugin("SpellChecker");
HTMLArea.onload = function() {
var editor1 = new HTMLArea("editor1");
editor1.registerPlugin(SpellChecker);
editor1.generate();
};
HTMLArea.init();
</script>
Next, do a search for the textarea in that particular file and add id="editor1"
Text Formatted Code
<textarea id="editor1" name="introtext" ...
if you have two textareas in one file (such as admin/story/storyeditor.thtml) use the following and be sure to add id="editor2" to the second textarea field:
Text Formatted Code
<script type="text/javascript">
HTMLArea.loadPlugin("SpellChecker");
HTMLArea.onload = function() {
var editor1 = new HTMLArea("editor1");
editor1.registerPlugin(SpellChecker);
editor1.generate();
var editor2 = new HTMLArea("editor2");
editor2.registerPlugin(SpellChecker);
editor2.generate();
};
HTMLArea.init();
</script>
Good Luck.
-- destr0yr
"I love deadlines. I like the whooshing sound they make as they fly by." -- Douglas Adams