You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Paul Uszak <pa...@klickngo.com> on 2007/08/08 20:08:02 UTC

How to generate an ANCHOR tag dynamically?

Hi all.

Is there any way to make a dynamic anchor tag in a struts link?  I'm also 
using tiles. The following does not work as the JSP interpreter can't...

<html:link action="showsitehelp.do"   anchor="<tiles:getAsString 
name="helppointer" />" >

I'm trying to have a link to a help page that's context sensitive, so where 
ever you are pressing help takes you to the appropriate point on the help page. 
Is there any other way of doing this please?

Thanks in advance.


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


Re: How to generate an ANCHOR tag dynamically?

Posted by Paul Benedict <pb...@apache.org>.
Use the Tiles tag that can expose the tiles attribute as a page attribute.
Maybe getAsString can do it. But once it is a page attribute, you can do:

<html:link anchor="${myvar}" />

Paul

On 8/8/07, Paul Uszak <pa...@klickngo.com> wrote:
>
> Hi all.
>
> Is there any way to make a dynamic anchor tag in a struts link?  I'm also
> using tiles. The following does not work as the JSP interpreter can't...
>
> <html:link action="showsitehelp.do"   anchor="<tiles:getAsString
> name="helppointer" />" >
>
> I'm trying to have a link to a help page that's context sensitive, so
> where
> ever you are pressing help takes you to the appropriate point on the help
> page.
> Is there any other way of doing this please?
>
> Thanks in advance.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
> For additional commands, e-mail: user-help@struts.apache.org
>
>