You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@commons.apache.org by Dan Yoder <da...@zeraweb.com> on 2004/09/13 21:37:57 UTC
namespace / quote problem in Jelly
Jelly is stripping the trailing quote from namespace declarations when I
try to output XML, as in:
<?xml version="1.0"?>
<j:jelly trim="false" xmlns:j="jelly:core" xmlns:x="jelly:xml">
<foo foo:bar="bar" xmlns:foo="http://schemas.acme.org/foo">
hello world
</foo>
</j:jelly>
which, when run with the following code:
File file = new File( "test-data/SOAP1.xml" );
StringWriter writer = new StringWriter();
XMLOutput buffer = XMLOutput.createXMLOutput( writer );
JellyContext context = new JellyContext();
context.setVariable("operation","findById");
context.runScript( file, buffer );
String output = writer.getBuffer().toString();
System.out.println(output);
returns the following XML (note the missing quote at the end of the
namepsace delcaration:
<foo xmlns:foo="http://schemas.acme.org/foo bar="bar">
hello world
</foo>
Please help!
regards,
-dan
dan@zeraweb.com
---------------------------------------------------------------------
To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-user-help@jakarta.apache.org
Re: [jelly] namespace / quote problem in Jelly
Posted by Paul Libbrecht <pa...@activemath.org>.
This was a problem with the dom4j outputter and is definitely fixed
since the skip dom4j 1.5. So the beta-4 fixes it.
paul
Le 14 sept. 04, à 02:11, Bill Keese a écrit :
> This is an old problem (caused by an old bug in xerces?) but I assume
> it's fixed in the new jelly beta release.
>
> Dan Yoder wrote:
>
>> Jelly is stripping the trailing quote from namespace declarations
>> when I try to output XML, as in:
>>
>> <?xml version="1.0"?>
>> <j:jelly trim="false" xmlns:j="jelly:core" xmlns:x="jelly:xml">
>> <foo foo:bar="bar" xmlns:foo="http://schemas.acme.org/foo">
>> hello world
>> </foo>
>> </j:jelly>
---------------------------------------------------------------------
To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-user-help@jakarta.apache.org
Re: [jelly] namespace / quote problem in Jelly
Posted by Dan Yoder <da...@zeraweb.com>.
Yep. I had to switch to DOM4J 1.5. The bug in my original post is
related to an XMLWriter problem in 1.4-dev-8
Bill Keese wrote:
> This is an old problem (caused by an old bug in xerces?) but I assume
> it's fixed in the new jelly beta release.
>
> Dan Yoder wrote:
>
>> Jelly is stripping the trailing quote from namespace declarations
>> when I try to output XML, as in:
>>
>> <?xml version="1.0"?>
>> <j:jelly trim="false" xmlns:j="jelly:core" xmlns:x="jelly:xml">
>> <foo foo:bar="bar" xmlns:foo="http://schemas.acme.org/foo">
>> hello world
>> </foo>
>> </j:jelly>
>>
>> which, when run with the following code:
>>
>> File file = new File( "test-data/SOAP1.xml" );
>> StringWriter writer = new StringWriter();
>> XMLOutput buffer = XMLOutput.createXMLOutput( writer );
>> JellyContext context = new JellyContext();
>> context.setVariable("operation","findById");
>> context.runScript( file, buffer );
>> String output = writer.getBuffer().toString();
>> System.out.println(output);
>>
>> returns the following XML (note the missing quote at the end of the
>> namepsace delcaration:
>>
>> <foo xmlns:foo="http://schemas.acme.org/foo bar="bar">
>> hello world
>> </foo>
>>
>> Please help!
>>
>> regards,
>> -dan
>>
>> dan@zeraweb.com
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
>> For additional commands, e-mail: commons-user-help@jakarta.apache.org
>>
>>
>>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: commons-user-help@jakarta.apache.org
>
---------------------------------------------------------------------
To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-user-help@jakarta.apache.org
Re: [jelly] namespace / quote problem in Jelly
Posted by Bill Keese <bi...@tech.beacon-it.co.jp>.
This is an old problem (caused by an old bug in xerces?) but I assume
it's fixed in the new jelly beta release.
Dan Yoder wrote:
> Jelly is stripping the trailing quote from namespace declarations when
> I try to output XML, as in:
>
> <?xml version="1.0"?>
> <j:jelly trim="false" xmlns:j="jelly:core" xmlns:x="jelly:xml">
> <foo foo:bar="bar" xmlns:foo="http://schemas.acme.org/foo">
> hello world
> </foo>
> </j:jelly>
>
> which, when run with the following code:
>
> File file = new File( "test-data/SOAP1.xml" );
> StringWriter writer = new StringWriter();
> XMLOutput buffer = XMLOutput.createXMLOutput( writer );
> JellyContext context = new JellyContext();
> context.setVariable("operation","findById");
> context.runScript( file, buffer );
> String output = writer.getBuffer().toString();
> System.out.println(output);
>
> returns the following XML (note the missing quote at the end of the
> namepsace delcaration:
>
> <foo xmlns:foo="http://schemas.acme.org/foo bar="bar">
> hello world
> </foo>
>
> Please help!
>
> regards,
> -dan
>
> dan@zeraweb.com
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: commons-user-help@jakarta.apache.org
>
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-user-help@jakarta.apache.org