NAME
Apache::AxKit::Language::SpellCheck - XML Text Spell Checker
SYNOPSIS
AxAddStyleMap text/x-spell-check Apache::AxKit::Language::SpellCheck
Alias /spell/ /path/to/docroot
<Location /spell/>
SetHandler axkit
AxResetProcessors
AxAddProcessor text/x-spell-check NULL
</Location>
SetHandler axkit
AxAddProcessor text/xsl /stylesheets/scrub-xml.xsl
AxAddProcessor text/x-spell-check NULL
AxAddProcessor text/xsl /stylesheets/display-html.xsl
DESCRIPTION
This language module processes an incoming XML document, either loaded from disk or returned from the previous pipeline stage, and processes its text nodes with Text::Aspell. It injects additional XML elements in the document representing which words are incorrectly spelled, and optionally offers spelling suggestions.
The XML elements injected into the source document appear similar to the following, though without the exta whitespace.
<sp:incorrect xmlns:sp="http://axkit.org/2004/07/17-spell-check#">
<sp:suggestion>CASS</sp:suggestion>
<sp:suggestion>CUSS</sp:suggestion>
<sp:word>CSS</sp:word>
</sp:incorrect>
OPTIONS
The following options can be used to change the default behavior of this language module:
AxSpellLanguage
PerlSetVar AxSpellLanguage fr
Use this directive to change the language you wish to use when checking spelling. Defaults to "en_US".
AxSpellSuggestions
PerlSetVar AxSpellSuggestions 5
Indicates the maximum number of spelling suggestions to return. This defaults to 3. If set to 0, then no suggestions are ever returned.
BUGS
Doesn't process attribute text
Has no facility for specifying alternate spelling databases