cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Bruce Krautbauer" <bruce.krautba...@medtronic.com>
Subject RE: Session transformer and namespaces
Date Thu, 13 Jun 2002 20:21:54 GMT
Maybe it's just IE.  The error I get when trying to display this output (as the result of a
<map:serialize type="xml"/>) is:
<error>
The XML page cannot be displayed 
Cannot view XML input using XSL style sheet. Please correct the error and then click the Refresh
button, or try again later. 


--------------------------------------------------------------------------------

Duplicate attribute. Error processing resource 'http://localhost:8080/cdemo/rootTest'. Line
5, Position 53 
 

 <root xmlns="http://cocoon.apache.org/session/1.0" xmlns="http://cocoon.apache.org/session/1.0"
xmlns="http://cocoon.apache.org/session/1.0"><a>foo</a>
----------------------------------------------------^
</error>

The 'view source' is:

<source>
<?xml version="1.0" encoding="UTF-8"?>
<test>
	
	
	<root xmlns="http://cocoon.apache.org/session/1.0" xmlns="http://cocoon.apache.org/session/1.0"
xmlns="http://cocoon.apache.org/session/1.0"><a>foo</a>
		<b>bar</b>
	</root>
</test>
</source>

I tried putting a copy-of identity transform in between the session transform and the XML
serialize to see if Xerces/Xalan would complain.  They didn't but I get an equally puzzling
error from IE:

<error>
The XML page cannot be displayed 
Cannot view XML input using XSL style sheet. Please correct the error and then click the Refresh
button, or try again later. 


--------------------------------------------------------------------------------

A name contained an invalid character. Error processing resource 'http://localhost:8080/cdemo/rootTest'.
Line 5, Position 14 
 

 <root xmlns:%@$#^@#="%@$#^@#" xmlns="http://cocoon.apache.org/session/1.0"><a xmlns="http://namespace.org/a">foo</a>
-------------^
</error>

the 'view source' is:

<source>
<?xml version="1.0" encoding="UTF-8"?>
<test>
	
	
	<root xmlns:%@$#^@#="%@$#^@#" xmlns="http://cocoon.apache.org/session/1.0"><a xmlns="http://namespace.org/a">foo</a>
		<b>bar</b>
	</root>
</test>
</source>

The good news is that the namespace for the 'a' element seems to be coming through.

?????

>>> Peter.Hunsberger@stjude.org 06/13/02 12:56PM >>>
> creates the following invalid XML output (there are multiple xmlns
attributes on the 'root' element):
> 
> <?xml version="1.0" encoding="UTF-8"?>
> <test>
> 	<root xmlns="http://cocoon.apache.org/session/1.0"
xmlns="http://cocoon.apache.org/session/1.0"
xmlns="http://cocoon.apache.org/session/1.0">
> 		<a>foo</a>
> 		<b>bar</b>
> 	</root>
> </test>

Umm, the XML might not be what you want, but it's not illegal;  an element
can have multiple namespaces....

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

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



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

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


Mime
View raw message