struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Cedric Dumoulin <cedric.dumou...@lifl.fr>
Subject Re: Struts 1.1 and Tiles
Date Tue, 19 Feb 2002 10:14:30 GMT

  Hi Dave,

  The normal way to use Tiles with Struts is to write your own action forwarding to a
logical name. This logical name can be linked to a Tile definition name :
  <action     path="/test/testAction"
           type="org.apache.struts.example.tiles.test.TestActionTileAction">
      <forward  name="success"        path="test.struts.action"/>
      <forward  name="failure"           path="test.struts.action.fail"/>
  </action>
  Check examples coming with Tiles to know more.

  The "org.apache.struts.actions.ForwardAction" do itself the forward to the page, and
is actually not designed to run with Tiles. It is easy to write a similar class to run
with Tiles : copy method processForward(...) in
org.apache.struts.tiles.ActionComponentServlet
to your new class. Copy method perform(...) from ForwardAction, and modify this later
to call processForward(...) rather than doing rd.forward().

  Cedric


Dave Weis wrote:

> Hi Cedric
>
> I just downloaded tiles from your site and am proceeding to learn a few
> things. Is org.apache.struts.actions.ForwardAction updated to use the
> tiles functionality? I tried the line below and got an error:
>
> <action path="/admin/message/read"
>         type="org.apache.struts.actions.ForwardAction"
>         parameter="dave.test" />
>
> Error:
> java.lang.IllegalArgumentException: path must be absolute: `dave.test'
>
> Is this a known problem or am I doing something incorrectly?
>
> dave
>
> >
> > Dave Weis wrote:
> >
> > > How are the two shaping up? Are there still problems using a newer version
> > > of struts with tiles? There are some features of 1.1 that I need such as
> > > the dynamic forms. Also, would a nightly Struts download be in the 1.1
> > > series or will it be 1.0.2 with some additional fixes?
> > >
> > > Thanks
> > > dave
> > >
> > > --
> > > Dave Weis             "I believe there are more instances of the abridgement
> > > djweis@sjdjweis.com   of the freedom of the people by gradual and silent
> > >                       encroachments of those in power than by violent
> > >                       and sudden usurpations."- James Madison
> > >
> > > --
> > > To unsubscribe, e-mail:   <mailto:struts-user-unsubscribe@jakarta.apache.org>
> > > For additional commands, e-mail: <mailto:struts-user-help@jakarta.apache.org>
> >
> >
> > --
> > To unsubscribe, e-mail:   <mailto:struts-user-unsubscribe@jakarta.apache.org>
> > For additional commands, e-mail: <mailto:struts-user-help@jakarta.apache.org>
> >
>
> --
> Dave Weis             "I believe there are more instances of the abridgement
> djweis@sjdjweis.com   of the freedom of the people by gradual and silent
>                       encroachments of those in power than by violent
>                       and sudden usurpations."- James Madison
>
> --
> To unsubscribe, e-mail:   <mailto:struts-user-unsubscribe@jakarta.apache.org>
> For additional commands, e-mail: <mailto:struts-user-help@jakarta.apache.org>


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


Mime
View raw message