htmlArea

A directory of browser-based WYSIWYG editors

  MAIN
INDEX
SEARCH
POSTS
WHO'S
ONLINE
LOG
IN

Home: htmlArea 2: htmlArea 2 & 3 archive (read only): htmlArea v2.0 - Add-Ons:
Word Cleaner & cities, states, etc.


The htmlArea 2 & 3 editors have been discontinued.

We've made these forums available as a read-only reference and knowledge-base for people using or developing editors based on htmlArea 2 or 3.

Anyone who is interested in taking over version 2 or 3 is free to do so. All we ask is that you choose a new name that doesn't have "htmlarea" in it to avoid confusion with this site. We'll even give you a link in the directory to make it easier for people to find you. If you are developing or hosting an htmlArea based-editor under a new name, please submit it to our directory.

 


barcsdad
Novice

Mar 8, 2004, 1:37 PM

Post #1 of 2 (3228 views)
Shortcut
Word Cleaner & cities, states, etc. Can't Post

Has anyone noticed how spaces are stripped out after words that are location-related (i.e. city names, state names) when pasting text from a Word document? Is there a work-around for this? I've attached a sample Word document to test it out. Any info would be appreciated.

Marty
Attachments: sample.doc (24.5 KB)


barcsdad
Novice

Mar 9, 2004, 8:46 AM

Post #2 of 2 (3214 views)
Shortcut
Re: [barcsdad] Word Cleaner & cities, states, etc. [In reply to] Can't Post

I found my answer. Look for these two lines:

unclean = unclean.replace(/<\/?\w+:[^>]*>/gi, "");
unclean = unclean.replace(/<\\?\??xml[^>]>/gi, "");

...and add a space to the replace value...

unclean = unclean.replace(/<\/?\w+:[^>]*>/gi, " ");
unclean = unclean.replace(/<\\?\??xml[^>]>/gi, " ");

This seems to fix the problem. However, if there is a comma after the word, it will then have a space in between the word and the comma. But I found that if you switch to HTML view and then switch it back, it fixes itself! It also seems to fix it if you save it to a database. Hope this helps someone out with the same problem.

Marty

 
 
 


Search for (options)