You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by "Struts Newsgroup (@Basebeans.com)" <st...@basebeans.com> on 2002/07/24 18:10:02 UTC
ForwardAction and tiles
Subject: ForwardAction and tiles
From: "Eric" <er...@enhansiv.com>
===
Does anyone know how ForwardAction works with tiles?
I have a jsp page that define a link to call a forward action, the forward
suppose to direct to another jsp page define in tiles. But I got the
following error.
javax.servlet.ServletException: Path site.login.page does not start with a
"/" character
Anyone has a clue?
Eric
--struts-config.xml
<action path="/gologin"
name="loginForm"
input="/index.jsp"
parameter="site.login.page" <!-- here is the page I want to
go -->
type="org.apache.struts.actions.ForwardAction"
scope="request"
validate="false">
</action>
--tiles-defs.xml
<definition name="site.mainLayout" path="/layouts/classicLayout.jsp">
<put name="title" value="My Project" />
<put name="header" value="/components/header.jsp" />
<put name="menu" value="site.menu.bar" />
<put name="footer" value="/components/footer.jsp" />
<put name="body" value="CHANGE ME" />
</definition>
...
<!-- the page defines here -->
<definition name="site.login.page" extends="site.mainLayout" >
<put name="title" value="Login" />
<put name="body" value="/security/loginBody.jsp" />
</definition>
--one of jsp page, I define a link to call the forward action
<html:link page="/action/gologin">
<bean:message key="index.link.login"/>
</html:link>
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>
Re: ForwardAction and tiles
Posted by Eddie Bush <ed...@vestus.adabbs.com>.
Yes! I cracked this nut just tonight. You don't want ForwardAction,
you want <digs-through-config/>
org.apache.struts.tiles.actions.NoOpAction. You've got to use the
_tiles_ actions if you want to forward to definitions. The standard
Struts ones don't seem to work. If someone knows another way, please
let us know! I have a bad feeling about how this is going to work with
the Validator framework ... or NOT work rather. I say that because you
have to extend Validator forms in order for that stuff to "work" - at
least, the way I understand it you do.
Regards,
Eddie
Struts Newsgroup (@Basebeans.com) wrote:
>Subject: ForwardAction and tiles
>From: "Eric" <er...@enhansiv.com>
> ===
>Does anyone know how ForwardAction works with tiles?
>
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>