You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by "Wilson, Colin" <co...@metoffice.com> on 2003/10/27 11:41:50 UTC
Absolute path of uri within xsp
How can I find the absolute path of the requested uri within an xsp
sheet. I mean this is what I'd LIKE to do.
<xsp:logic>
String uri = <xsp-request:get-uri as="string"/>;
File file=new File(uri);
</xsp:logic>
<xsp:expr>file.getAbsolutePath()</xsp:expr>
how to dynamically set the name for xsp element
Posted by Jian Dai <ja...@comcast.net>.
Hi, all:
Does anybody know how we can dynamically name for xsp element?
Suppose that we have a xsp elelement like
<xsp:element name="myname">blab, blab</xsp:element>
I would like to know if there is a way to set the value of "myname"
dynamically during the running time.
Thanks for the nice help.
Jack
-----Original Message-----
From: Joerg Heinicke [mailto:jheinicke@virbus.de]
Sent: Monday, October 27, 2003 11:45 AM
To: users@cocoon.apache.org
Subject: Re: Absolute path of uri within xsp
On 27.10.2003 11:41, Wilson, Colin wrote:
> How can I find the absolute path of the requested uri within an xsp
> sheet. I mean this is what I'd LIKE to do.
>
> <xsp:logic>
> String uri = <xsp-request:get-uri as="string"/>;
> File file=new File(uri);
> </xsp:logic>
> <xsp:expr>file.getAbsolutePath()</xsp:expr>
I don't really understand your question. Isn't <xsp-request:get-uri
as="string"/> already an absolute path?
Joerg
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org
Re: Absolute path of uri within xsp
Posted by Joerg Heinicke <jh...@virbus.de>.
On 27.10.2003 11:41, Wilson, Colin wrote:
> How can I find the absolute path of the requested uri within an xsp
> sheet. I mean this is what I'd LIKE to do.
>
> <xsp:logic>
> String uri = <xsp-request:get-uri as="string"/>;
> File file=new File(uri);
> </xsp:logic>
> <xsp:expr>file.getAbsolutePath()</xsp:expr>
I don't really understand your question. Isn't <xsp-request:get-uri
as="string"/> already an absolute path?
Joerg
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org