You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by Isabelle Boyer <ib...@capgemini.fr> on 2001/05/10 11:04:35 UTC

[C1] : accent interpretation !

Hi all,

I do a SQL request in my xml document and the data are already in html
format (i.e "é" is writing &eacute; and etc..) in the database.

The request is done but in the result, the accent are not interpreted
correctly.
 Here is what 's happend : the character "&" is interpreted in "&amp;" so
the rest is not right.

In the code source I have : G&amp;eacute;raldine instaed of Géraldine.

I have changed successively the cocoon format in <?cocoon-format
type="text/html/loose"?> and <?cocoon-format type="text/html"?>
but any change appears.

Someone has raised this problem before !

I have tried to insert the following code in order to ignore the character
"&" thus is not interpreted but it is not working..

<!DOCTYPE page [
<!ENTITY amp "&#38;">
]>


Anyone has an idea..???
Could you suggest me other modification to do ?

Thank for your help. ;-)

Isabelle.


---------------------------------------------------------------------
Please check that your question has not already been answered in the
FAQ before posting. <http://xml.apache.org/cocoon/faqs.html>

To unsubscribe, e-mail: <co...@xml.apache.org>
For additional commands, e-mail: <co...@xml.apache.org>


Re: [C1] : accent interpretation !

Posted by Sebastien Koechlin <sk...@ivision.fr>.
Isabelle Boyer wrote:
> I do a SQL request in my xml document and the data are already in html
> format (i.e "é" is writing &eacute; and etc..) in the database.
> 
> The request is done but in the result, the accent are not interpreted
> correctly.
>  Here is what 's happend : the character "&" is interpreted in "&amp;" so
> the rest is not right.

You have to parse the result, I don't think a DOM Tree has any encoding,
just
unicode strings. If you are using esql; you can try to adapt
'esql:get-xml'
to use jTidy, or use a custom EntityResolver with your parser.

-- 
Sébastien Koechlin - IVision - skoechlin@ivision.fr

---------------------------------------------------------------------
Please check that your question has not already been answered in the
FAQ before posting. <http://xml.apache.org/cocoon/faqs.html>

To unsubscribe, e-mail: <co...@xml.apache.org>
For additional commands, e-mail: <co...@xml.apache.org>