6.0.0-beta1
7/29/25

[#2060] Spell check with aspell in HTML mode erroring on some HTML tags
Summary Spell check with aspell in HTML mode erroring on some HTML tags
Queue IMP
Queue Version HEAD
Type Bug
State Resolved
Priority 1. Low
Owners selsky (at) columbia (dot) edu
Requester kevin_myer (at) iu13 (dot) org
Created 06/01/2005 (7363 days ago)
Due
Updated 06/02/2005 (7362 days ago)
Assigned 06/02/2005 (7362 days ago)
Resolved 06/02/2005 (7362 days ago)
Github Issue Link
Github Pull Request
Milestone
Patch No

History
06/02/2005 08:30:13 AM Matt Selsky Comment #7
State ⇒ Resolved
Reply to this comment
Fixed in 4.0.4 and CVS.
06/02/2005 08:14:21 AM Matt Selsky Comment #6 Reply to this comment
Cool.  The leading dash of the sig line was making aspell switch to 
Nroff mode.


06/02/2005 02:31:24 AM kevin_myer (at) iu13 (dot) org Comment #5 Reply to this comment
That seems to do the trick, at least for a simple test case of my 
signature.  I have it installed on our production site and will watch 
the Apache logs to see if it collects any garbage there, like it has 
been.
06/02/2005 01:48:59 AM Matt Selsky Assigned to Matt Selsky
 
06/02/2005 01:45:46 AM Matt Selsky Comment #4
New Attachment: spell.patch Download
Reply to this comment
Try this?
06/02/2005 12:37:06 AM kevin_myer (at) iu13 (dot) org Comment #3 Reply to this comment
My suspicion is that certain tags (i.e. <a>) aren't going to cause a 
spell checker to choke, because "a" is a valid word.  But a break tag 
<br /> does - "br" is not a valid word.



Run the test file for the bug I filed on the aspell SF site through 
aspell on the commandline:



aspell -a -H < spellfile



and watch it kick out errors (at least it does for me on two different 
operating systems).



Then prepend ^ to each line - errors are gone for HTML tags.



Works:



^<br />

^<br />

^-- <br />

^Kevin M. Myer<br>

^Senior Systems Administrator<br />

^Lancaster-Lebanon Intermediate Unit 13<br />



Doesn't work:

<br />

<br />

-- <br />

Kevin M. Myer<br>

Senior Systems Administrator<br />

Lancaster-Lebanon Intermediate Unit 13<br />



And just to prove that out, add the word "mispeling" to the first 
entry - it gets flagged as mispelled and suggestions are given.
06/02/2005 12:20:19 AM Matt Selsky Comment #2
State ⇒ Feedback
Reply to this comment
This works for me in HTML mode.  When not in HTML mode (but I add html 
code into the message), adding "^" to the start of every line still 
seemed to generate spelling errors.  imp/spellling.php doesn't add the 
"-H" (or -h) flag to aspell unless you are in HTML composition mode.
06/01/2005 02:34:40 AM kevin_myer (at) iu13 (dot) org Comment #1
State ⇒ Unconfirmed
Priority ⇒ 1. Low
Type ⇒ Bug
Summary ⇒ Spell check with aspell in HTML mode erroring on some HTML tags
Queue ⇒ IMP
Reply to this comment
http://sourceforge.net/tracker/index.php?func=detail&aid=1182195&group_id=245&atid=100245



The word from the author is that using aspell in pipe mode requires 
use of the "^", which I found buried in some Texinfo documentation for 
aspell.



So I'm assuming you'd need to break the form data submitted for 
'currmsg' up into strings, and insert a '^' at the beginning of each 
line.  aspell returns no errors on a test file I run through on the 
command line, with carats.  The way its done now, all the form data is 
written out in one chunk.  Ugly hack would be to write the file out, 
then open it again, reading a line at a time and writing it out while 
prepending a carat to the begining of each line.

Saved Queries