You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Marco Machmer <ma...@morca.de> on 2007/11/05 13:14:18 UTC

[S2] getText() and #attr

hi folks,

can i use #attr inside the getText()-methode?
here my problem:
<s:url id="image"
value="%{getText(common.themes.#attr.THEME.reference.edit.24)}"/>
the key will not be found.

whats wrong

regards marco machmer
-- 
View this message in context: http://www.nabble.com/-S2--getText%28%29-and--attr-tf4751113.html#a13585395
Sent from the Struts - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Re: [S2] getText() and #attr

Posted by Marco Machmer <ma...@morca.de>.
hi Vinicius,

this works fine.
the correct syntax for me is:
 <s:url id="image" value="%{getText('common.themes.'+#attr.THEME +
'.reference.edit.24')}"/>
because the variable THEME is stored in the request or session or action.

thanx a lot.

regards marco


Vinicius Medeiros Peretti wrote:
> 
> Hi Marco
> I use:
> value="%{getText( #Variable+'.string.constant.label.'+OtherVariable)}"
> 
> try:
> 
> <s:url id="image"
> value="%{getText('common.themes.'+#attr+'.THEME.reference.edit.24')}"/>
> 
> regards,
> Vinicius
> 
> Marco Machmer wrote:
>> hi folks,
>>
>> can i use #attr inside the getText()-methode?
>> here my problem:
>> <s:url id="image"
>> value="%{getText(common.themes.#attr.THEME.reference.edit.24)}"/>
>> the key will not be found.
>>
>> whats wrong
>>
>> regards marco machmer
>>   
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
> For additional commands, e-mail: user-help@struts.apache.org
> 
> 
> 

-- 
View this message in context: http://www.nabble.com/-S2--getText%28%29-and--attr-tf4751113.html#a13602772
Sent from the Struts - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Re: [S2] getText() and #attr

Posted by Vinicius Medeiros Peretti <vi...@peretti.eti.br>.
Hi Marco
I use:
value="%{getText( #Variable+'.string.constant.label.'+OtherVariable)}"

try:

<s:url id="image"
value="%{getText('common.themes.'+#attr+'.THEME.reference.edit.24')}"/>

regards,
Vinicius

Marco Machmer wrote:
> hi folks,
>
> can i use #attr inside the getText()-methode?
> here my problem:
> <s:url id="image"
> value="%{getText(common.themes.#attr.THEME.reference.edit.24)}"/>
> the key will not be found.
>
> whats wrong
>
> regards marco machmer
>   


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org