htmlArea

A directory of browser-based WYSIWYG editors

  MAIN
INDEX
SEARCH
POSTS
WHO'S
ONLINE
LOG
IN

Home: htmlArea 3 (beta): htmlArea 2 & 3 archive (read only): htmlArea v3.0 - Discussion:
Unicode bug I *think*


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.

 


bignose
New User

Jan 10, 2005, 8:30 AM

Post #1 of 7 (2977 views)
Shortcut
Unicode bug I *think* Can't Post

Hi Folks,

I'm pretty new to this encoding/unicode business. Here's my scenerio.

One of our users wants to take teh content at
http://www.voyageurquest.com/algonquin-cottages.php#87'

And copy/paste that section into an HTML area in our app.
Our app then takes that html, encodes all </>'s to &glt; etc, and stores it wrapped in some XML phrases.

The the postgresql database uses pgxml to get the databack out. However the pgxml functions are dying, presumably because some weird characters are in the mix.

I'm trying to trace this bug down with the pgXML folks as well, but if anyone can offer a tip, it would be greatly appreciated.

Jeff.


sleemanj
User

Jan 10, 2005, 10:37 AM

Post #2 of 7 (2963 views)
Shortcut
Re: [bignose] Unicode bug I *think* [In reply to] Can't Post

Exactly which characters are you encoding to their respective entities?

In XML only <, >, & and " should (and must) be encoded in attributes & character data unless you have specifically added other entities via referencing a DTD in the XML.

Have a look at the XML you are generating, if it contains any entities other than &amp;, &lt;, &gt; and &quot; then that could be your problem.


James Sleeman
PHP Programmer


bignose
New User

Jan 10, 2005, 10:42 AM

Post #3 of 7 (2960 views)
Shortcut
Re: [sleemanj] Unicode bug I *think* [In reply to] Can't Post

That's not the issue. Cause if i take what is in the databse, and copy it to notepad, then back to the database, it works fine.

So there is an unprintable character somewhere that is gumming up the pgxml works.


sleemanj
User

Jan 10, 2005, 6:50 PM

Post #4 of 7 (2950 views)
Shortcut
Re: [bignose] Unicode bug I *think* [In reply to] Can't Post

Ok, try utf8_encode()'ing the data befor you wrap it in the XML. utf8_encode() will take data in another character set and encode it to utf8 (as best it can).

Your data may be in ISO8859-1 and contains non-english european characters, which are invalid utf-8.


James Sleeman
PHP Programmer


bignose
New User

Jan 11, 2005, 11:54 AM

Post #5 of 7 (2936 views)
Shortcut
Re: [sleemanj] Unicode bug I *think* [In reply to] Can't Post

is utf8_unicode a perl thing, or a javascript ?

I did a google and php was the first lang that came up but we're not using that.

I'll look for a perl alternative.


jaspertje
Novice

Jan 11, 2005, 12:48 PM

Post #6 of 7 (2932 views)
Shortcut
Re: [bignose] Unicode bug I *think* [In reply to] Can't Post

If ure gonna save it in XML, why dont u use CDATA ?


sleemanj
User

Jan 11, 2005, 9:53 PM

Post #7 of 7 (2906 views)
Shortcut
Re: [bignose] Unicode bug I *think* [In reply to] Can't Post

Sorry, I thought you were using PHP.


James Sleeman
PHP Programmer

 
 
 


Search for (options)