cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Robin Green" <>
Subject RE: logic
Date Wed, 09 Aug 2000 11:17:09 GMT
All the answers so far have been wrong.

"Chris Newland" <> wrote:
>If you want to use the < and > characters (and many others) in your XSP 

That's not what Maris is trying to do!

Maris wrote:
>Any error in this code.  Cocoon gives me error.
>  <xsp:logic>
>   String data="<xsl:value-of select="text()" />";

That would work fine if the node you were inserting were all one line, e.g.

  <mynode>I am inserting this text</mynode>

However it seems that the node you are inserting has a new line character in 
it, e.g.

    I am inserting this text

String literals in Java cannot have newline characters. Strings can have 
them, but not string literals. To solve your problem either

a) Take out all the newlines from all the nodes that will be fetched by this 

or if that is not possible in general

b) Rethink your approach. Including lots of literal data in XSP is not a 
good strategy because it will fail once you reach 64K of code. What are you 
trying to do overall? What's the big picture?

Robin Green
i-tao Ltd.
4 Skyline Village
London E14 9TS
United Kingdom
Phone +44 20 7537 2233  Fax +44 70 8081 5118

Get Your Private, Free E-mail from MSN Hotmail at

View raw message