You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by Oskar Casquero <jt...@bi.ehu.es> on 2002/11/05 17:31:03 UTC
"xml version" procesing instruction and text serializer?
I want to obtain a text file (not xml) from an XSLT transformation. The problem is that after doing the transformation and serializing the result with a text serializer, the <?xml version="1.0"?> processing instruction appears at the beginning of the text file, so I have to delete it manually. Do I have to modify text serializer or is there another way to delete the <?xml version="1.0"?> processing instruction?
Oskar
: Bug with Cocoon? or Bug with programmer?
Posted by Tom Place <tr...@cs.nott.ac.uk>.
Hi All,
I emailed recently about a problem using session variables in cocoon
(this was solved by the modifying of config.xconf - thanks to Sylvain
Wallez).
Now the problem I have is the following line in XSP :
<xsp-session:set-attribute>name="fruit">Apple</xsp-session:set-attribute
>
generates the following JSP :
XSPRequestHelper.setSessionAttribute(objectModel,
String.valueOf("verified"),
this.characters("False");
);
Now I'm sure most of you will be able to spot a miss-placed semicolon
after the ("False") which gives me a compilation error.
However if I put the following XSP in it seams to cure this :
String myParam = "Apple";
<xsp-session:set-attribute>name="fruit"><xsp:expr>myParam</xsp:expr></xs
p-session:set-attribute>
I get correct JSP generated (at that point anyway). However I still get
a NullPointerException.
This originates at
org.apache.cocoon.components.language.markup.xsp.XSPRequestHelper.setSes
sionAttribute(XSPRequestHelper.java:454)
Anyone come across this before?
I am using Cocoon 2.03 running on Tomcat 4.1.12
Cheers
Tom Place
---------------------------------------------------------------------
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: <co...@xml.apache.org>
For additional commands, e-mail: <co...@xml.apache.org>
Re: "xml version" procesing instruction and text serializer?
Posted by Oskar Casquero <jt...@bi.ehu.es>.
I've included it and the xml declaration still appears. Do you know if the
<omit-xml-declaration> parameter is also valid for the text serializer?
Oskar
----- Original Message -----
From: "Ryan Agler" <ry...@hotmail.com>
To: <co...@xml.apache.org>
Sent: Tuesday, November 05, 2002 8:09 PM
Subject: RE: "xml version" procesing instruction and text serializer?
In your XSLT file, right under xsl:stylesheet, include:
<xsl:output omit-xml-declaration="yes" method="text" />
-----Original Message-----
From: Oskar Casquero [mailto:jtacaoio@bi.ehu.es]
Sent: Tuesday, November 05, 2002 11:31 AM
To: cocoon-users@xml.apache.org
Subject: "xml version" procesing instruction and text serializer?
I want to obtain a text file (not xml) from an XSLT transformation. The
problem is that after doing the transformation and serializing the
result with a text serializer, the <?xml version="1.0"?> processing
instruction appears at the beginning of the text file, so I have to
delete it manually. Do I have to modify text serializer or is there
another way to delete the <?xml version="1.0"?> processing instruction?
Oskar
---------------------------------------------------------------------
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: <co...@xml.apache.org>
For additional commands, e-mail: <co...@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: <co...@xml.apache.org>
For additional commands, e-mail: <co...@xml.apache.org>
RE: "xml version" procesing instruction and text serializer?
Posted by Ryan Agler <ry...@hotmail.com>.
In your XSLT file, right under xsl:stylesheet, include:
<xsl:output omit-xml-declaration="yes" method="text" />
-----Original Message-----
From: Oskar Casquero [mailto:jtacaoio@bi.ehu.es]
Sent: Tuesday, November 05, 2002 11:31 AM
To: cocoon-users@xml.apache.org
Subject: "xml version" procesing instruction and text serializer?
I want to obtain a text file (not xml) from an XSLT transformation. The
problem is that after doing the transformation and serializing the
result with a text serializer, the <?xml version="1.0"?> processing
instruction appears at the beginning of the text file, so I have to
delete it manually. Do I have to modify text serializer or is there
another way to delete the <?xml version="1.0"?> processing instruction?
Oskar
---------------------------------------------------------------------
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: <co...@xml.apache.org>
For additional commands, e-mail: <co...@xml.apache.org>