You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by "Sann, Stephan" <SS...@bhw.de> on 2002/06/17 11:58:32 UTC
Using the value of a request-parameter for the attribute of a custom tag
Hello List,
here is another newbie-question, so please bear with me again.
I searched the web for tree hours now and I didn't find the
key to the solution.
I'm trying to use the value of an request-parameter for the
attribute of a custom tag (<rtexprvalue>true</rtexprvalue>).
I know how to manage it with a scriptlet:
<mytaglib:atag coolattribute="<%= request.getParameter("thevalueforthecoolattribute") %>"/>
But using scriptlets is not what we want any more - we want to
use taglibs!
So I thougt if this works:
<bean:parameter id="thevalueforthecoolattribute" name="thevalueforthecoolattribute"/>
<bean:write name="thevalueforthecoolattribute"/>
this should work too:
<mytaglib:atag coolattribute="<bean:parameter id="thevalueforthecoolattribute"
name="thevalueforthecoolattribute"/><bean:write name="thevalueforthecoolattribute"/>"/>
Unfortunately not!
Any ideas, workarounds, tips?
Thanx a lot!!!
Best regards
Stephan
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>
Re: Using the value of a request-parameter for the attribute of a custom tag
Posted by Slava_L <lo...@esstu.ru>.
so what's the problem ?
<bean:parameter id="pageName" name="paramName" value='default'/>
....
<mytaglib:atag coolattribute='<bean:write name="pageName"/>'/>
....
and USE NESTED quotation marks i.e.. " ' ' " and vice versa ' " " '
----- Original Message -----
From: "Sann, Stephan" <SS...@bhw.de>
To: <st...@jakarta.apache.org>
Sent: Monday, June 17, 2002 6:58 PM
Subject: Using the value of a request-parameter for the attribute of a
custom tag
Hello List,
here is another newbie-question, so please bear with me again.
I searched the web for tree hours now and I didn't find the
key to the solution.
I'm trying to use the value of an request-parameter for the
attribute of a custom tag (<rtexprvalue>true</rtexprvalue>).
I know how to manage it with a scriptlet:
<mytaglib:atag coolattribute="<%=
request.getParameter("thevalueforthecoolattribute") %>"/>
But using scriptlets is not what we want any more - we want to
use taglibs!
So I thougt if this works:
<bean:parameter id="thevalueforthecoolattribute"
name="thevalueforthecoolattribute"/>
<bean:write name="thevalueforthecoolattribute"/>
this should work too:
<mytaglib:atag coolattribute="<bean:parameter
id="thevalueforthecoolattribute"
name="thevalueforthecoolattribute"/><bean:write
name="thevalueforthecoolattribute"/>"/>
Unfortunately not!
Any ideas, workarounds, tips?
Thanx a lot!!!
Best regards
Stephan
--
To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
For additional commands, e-mail:
<ma...@jakarta.apache.org>
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>