Ah yes, that is a problem. You must strip xml declarations from xml, when inserting into an established dom. You shouldn't have to, but you do, to insert new xml into a dom that is already established, try this:

<@dominsert local$thexml xpath="/root/whatever"><@replace str='<@var local$mynewxmlstring>' findstr='<\?.+\?>' replacestr='' type=regex></@dominsert>

-- 

Robert Garcia
President - BigHead Technology
VP Application Development - eventpix.com
13653 West Park Dr
Magalia, Ca 95954
ph: 530.645.4040 x222 fax: 530.645.4040

On Jun 12, 2006, at 12:29 PM, Ben Johansen wrote:

I was wondering this myself, Im not quite sure of his intent,

but it looks like he is inserting a second header into an already established DOM
<xml version="1.0" encoding="iso-8859-1" standalone="no">

So wouldn't it be like

---------------------------------------------
<@DOMINSERT OBJECT=myDom SCOPE=request>
<DIV ID="1">
<P>Ceci est une exemple de Document structure</P>
</DIV>

<DIV ID="2">
<P>Paragraphe de texte de test</P>
<P>Suite du paragraphe de texte de test</P>
</DIV>
</@DOMINSERT>

@@request$myDom
---------------------------------------------

or he would need
to add some pathing into the @DOMINSERT

<@DOMINSERT OBJECT=myDom  XPATH="/" SCOPE=request>

Ben


On Jun 12, 2006, at 11:47 AM, Robert Garcia wrote:

I use them all the time, there are definitely tricks to it, but I have not seen it blow up witango, only it would not display properly, or mess up the characters, without crashing.

What version of witango server are you using? How are these characters getting into your xml, are they coming out of a DB, or from a form?

Unfortunately, witango does not support anything but ISO-8859-1 but should work with these characters.

-- 

Robert Garcia
President - BigHead Technology
VP Application Development - eventpix.com
13653 West Park Dr
Magalia, Ca 95954
ph: 530.645.4040 x222 fax: 530.645.4040

On Jun 12, 2006, at 10:02 AM, William M Conlon wrote:

I don't think the accented characters are in the iso-8859-1 character set.  Have you tried utf-8 encoding?

On Jun 12, 2006, at 2:55 AM, Francis Lebourq wrote:

Hi

I have an issue with <@DOMINSERT> command and accentuated characters (like éèàî...)

This code works fine

---------------------------------------------
<@DOMINSERT OBJECT=myDom SCOPE=request>
<xml version="1.0" encoding="iso-8859-1" standalone="no">
<DIV ID="1">
<P>Ceci est une exemple de Document structure</P>
</DIV>

<DIV ID="2">
<P>Paragraphe de texte de test</P>
<P>Suite du paragraphe de texte de test</P>
</DIV>
</xml>
</@DOMINSERT>

@@request$myDom
---------------------------------------------

because there is no accentuated characters.

But this code ...
---------------------------------------------
<@DOMINSERT OBJECT=myDom SCOPE=request>
<xml version="1.0" encoding="iso-8859-1" standalone="no">
<DIV ID="1">
<P>Ceci est une exemple de Document structuré</P> <<<< the diff is here
</DIV>

<DIV ID="2">
<P>Paragraphe de texte de test</P>
<P>Suite du paragraphe de texte de test</P>
</DIV>
</xml>
</@DOMINSERT>

@@request$myDom
---------------------------------------------

return an Error -902
An error occurred while parsing the XML.
Meta Stack Trace:
Line Meta Tag
0002 <@DOMINSERT OBJECT=myDom SCOPE=request> <xml version="1.0" encoding="iso-8859-1" standalone="no"> <DIV ID="1"> <P>Ceci est une exemple de Document structuré</P> </DIV> <DIV ID="2"> <P>Paragraphe de texte de test</P> <P>Suite du paragraphe de texte de test</P> </DIV> </xml> </@DOMINSERT>
*The meta stack is interpreted top-to-bottom: the top line shows the inner metatag that caused the error.



I have read the archives of the mailing list but i have get nothing.

I have forgot something ?

Regards

Francis LEBOURQ

________________________________________________________________________

Bill

William M. Conlon, P.E., Ph.D.
To the Point
345 California Avenue Suite 2
Palo Alto, CA 94306
   vox:  650.327.2175 (direct)
   fax:  650.329.8335
mobile:  650.906.9929

________________________________________________________________________

________________________________________________________________________



________________________________________________________________________

________________________________________________________________________
TO UNSUBSCRIBE: Go to http://www.witango.com/developer/maillist.taf

Reply via email to