Wintertree Software Inc.

Wintertree Spelling Server

Home Site index Contact us Catalog Shopping Cart Products Support Search

You are here: Home > Support > Wintertree Spelling Server > Misspelled words not detected after "&" or "<"


Misspelled words not detected after "&" or "<"

Problem: If the text being checked contains a "&" or "<" character, Spelling Server seems to stop checking. It won't find any misspelled words after the "&" or "<" character.

Discussion: This behavior is by design. It occurs when the WSS_IGNORE_HTML_MARKUPS_OPT option is enabled. When this option is enabled, the CheckText and CheckAllText methods expect the text to contain correctly formatted HTML. In correctly formatted HTML, the "&" and "<" are special characters (known as meta-characters). The "&" character is used to signal the beginning of an HTML character entity, such as "&copy;" for a copyright symbol. The "<" is used to signal the beginning of an HTML markup, such as "<b>" for boldface. When the CheckText or CheckAllText methods see these characters, they expect either a character entity or markup to follow. More accurately, they begins skipping text until they encounter the terminator of the character entity or markup, or the end of the current line. The terminator of a character entity is ";", and the terminator of a markup is ">". Thus, the appearance of "&" in the text acts like a switch that causes text to be skipped until a ";" appears (similarly for "<" and ">"). This behavior is documented in the Spelling Server user's guide in the description of the WSS_IGNORE_HTML_MARKUPS_OPT option.

Solution: Either disable WSS_IGNORE_HTML_MARKUPS_OPT, or ensure the text contains correctly formatted HTML. A literal "&" character should be entered as "&amp;", and a literal "<" character should be entered as "&lt;".


Home Site index Contact us Catalog Shopping Cart Products Support Search


Copyright © 2015 Wintertree Software Inc.