Is there a reasonable way to spell check an entire web site

Projects, workspaces, solutions, file management and CVS/SVN issues

Is there a reasonable way to spell check an entire web site

Postby TimP » Tue Sep 04, 2007 4:06 pm

I've got this site (actually it's a humongous help file) that could do with a spell check. I know there isn't a "spellcheck site" command, but I'm wondering if there's a canned scripting approach to iterating through all the files in a project so that I could maybe run the spellchecker on every file that way.
User avatar
TimP
Newbie
 
Posts: 4
Joined: Thu Sep 14, 2006 11:00 pm

Re: Is there a reasonable way to spell check an entire web s

Postby Mofi » Thu Sep 06, 2007 11:03 am

If you have the whole website offline available use command Quick Open to open all HTML files at once and then run the spell check on every file. Spell checking cannot be automized by a script because it always requires user interactions.

Hint: If you find a word mis-spelled in more than 1 file, use Replace All on all open files to faster correct all of them at once. It's annoying to correct a wrong written word dozens of times because it is wrong in dozens of files.
User avatar
Mofi
Grand Master
Grand Master
 
Posts: 3937
Joined: Thu Jul 29, 2004 11:00 pm
Location: Vienna

Re: Is there a reasonable way to spell check an entire web site

Postby TimP » Thu Sep 06, 2007 11:57 am

Mofi, Thanks for your suggestions. And hello back to you from Greely, Ontario, Canada.

I was afraid of this. The site is approximately 630 html files, so opening them all at once and then spell-checking them one at a time would really blow.

What I want is a way to make a list of all tokens in all the html files that:

- are not html, CSS, javascript, or whatever
- are not all uppercase
- don't have uppercase letters appearing among lowercase letters
- don't have numerals in them
- don't have underscores in them
- are not in my spelling dictionnary

This would result in a nice short list of new words and misspellings. I could then search for these words or the list maker could keep links to where the words were found.

Are there any ambitious developers out there who'd like to consider this? I'm quite sure someone besides poor sad me would find a use for this kind of tool.
User avatar
TimP
Newbie
 
Posts: 4
Joined: Thu Sep 14, 2006 11:00 pm

Re: Is there a reasonable way to spell check an entire web s

Postby Mofi » Thu Sep 06, 2007 12:10 pm

At Macro examples and reference for beginners and experts you can download a zip archive with some files. Inside the macro files there is the macro HtmlWordList. It is a macro I have written for myself for nearly what you want to do. As I have written in the UEM file you can use it and adapt it to your needs. For example you want to delete all blocks of CSS, JavaScript, PHP, etc.
Example for CSS deletion:

UnixReOff
Top
Loop
Find "<style"
IfNotFound
ExitLoop
EndIf
Key HOME
IfColNumGt 1
Key HOME
EndIf
StartSelect
Find Select "</style>[ ^t]++^p"
IfSel
Delete
EndIf
EndSelect
EndLoop
Top
User avatar
Mofi
Grand Master
Grand Master
 
Posts: 3937
Joined: Thu Jul 29, 2004 11:00 pm
Location: Vienna

Re: Is there a reasonable way to spell check an entire web site

Postby TimP » Thu Sep 06, 2007 12:36 pm

Wow! Thanks. I'm going to give this a close look.
User avatar
TimP
Newbie
 
Posts: 4
Joined: Thu Sep 14, 2006 11:00 pm


Return to Workspace Management

cron