cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Curro, Joseph" <Joseph.Cu...@time0.com>
Subject RE: URI escape
Date Mon, 10 Apr 2000 20:17:51 GMT
You can also read the encoded value into a variable, then reference that.
For example:

<xsl:variable name="what">
	<xsl:value-of
select="java:java.net.URLEncoder.encode('your-url-to-encode')"/>
</xsl:variable>
<A TARGET="wmMails" HREF="dummy.xml?action=show&amp;what={$what}">

Joe

> -----Original Message-----
> From: Donald Ball [mailto:balld@webslingerZ.com]
> Sent: Monday, April 10, 2000 4:09 PM
> To: cocoon-users@xml.apache.org
> Subject: Re: URI escape
> 
> 
> On Mon, 10 Apr 2000, Gabor Dolla wrote:
> 
> > > 
> > > With your last idea I receive the following:
> > > Call to extension function failed: method call/new failed:
> > > java.lang.NullPointerException
> > >
> > 
> > OK, your idea might work ..
> > 
> > > >    <xsl:value-of
> > > > select="java:java.net.URLEncoder.encode('your-url-to-encode')"/>
> > 
> > my problem is, that I produce HTML so I need the value in a 
> href, like
> > this:
> > <A TARGET="wmMails" HREF="dummy.xml?action=show&amp;
> > what={java:java.net.URLEncoder.encode(NAME)}">
> > 
> > Or is it not possible to use java:java.net.URLEncoder.encode
> > between {} ???
> > 
> > Then how can I use the encoded value in a href with 
> > <xsl:value-of select="....   ???
> 
> if nothing else, you can use xsl:attribute to create the HREF 
> attribute
> value.
> 
> - donald
> 
> 
> ---------------------------------------------------------------------
> 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