struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Allen Gilliland <>
Subject Re: struts2 equivalent of html:link tag?
Date Mon, 16 Apr 2007 21:08:28 GMT

Dave Newton wrote:
>> From: Allen Gilliland <>
>> that works fine for any actions that i have defined, but it doesn't work 
>> for non-struts actions.
> <s:url value="/ui/something.jsp"/>

okay, but at that point there is no real reason to use the s:url tag at 
all because i am no longer pointing to a logical name for my link.

as i said in my previous email, what i am basically looking for is a way 
to provide logical names for my links so that i can create one link for 
"login" and have all of my various forms and pages use that to build the 
url to the login page.  that way when i want to change the login url i 
only do it in one place, rather than in dozens of places.

in struts1 that was possible when using the html:link tag because if you 
put this in a page ...

<html:link forward="login">login page</html:link>

and had this in your struts config file ...

   <forward name="login" path="/ui/login-redirect.jsp"/>

then you would end up with this in your html ...

<a href="/ui/login-redirect.jsp">login page</a>

does struts2 have any equivalent for that?

-- Allen

> d.
> __________________________________________________
> Do You Yahoo!?
> Tired of spam?  Yahoo! Mail has the best spam protection around 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail:
> For additional commands, e-mail:

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message