The problem is now resolved with Struts 1.0 and tilesForStruts1.0.jar.
  You should be able to use directly  <action ... forward="aDefinition" /> in 
Struts1.0 as well as in Struts1.1.

    Cedric

[EMAIL PROTECTED] wrote:

> Hi,
>
> After searching the archives and receiving helpful suggestions from people
> on the list, it seem the only way to get tiles with struts forwards to work
> is to upgrade to Struts 1.1.
>
> I've made numerous attempts at getting it to work with Struts 1.0 with no
> luck.
>
> Using the tiles-blank-struts1-0.war provided with tiles,
>
> 1) I added the following action to the struts-config.xml file:
>
> <action path="/doYouWork" forward="site.index.page"/>
>
> -The layout 'site.index.page' is already defined in the
> tiles-blank-struts1-0.war app.
>
> 2) Made sure the following lines were commented out:
>
> <!--
> <controller processorClass="org.apache.struts.tiles.TilesRequestProcessor">
> </controller>
>
> <message-resource
> parameter="org.apache.struts.example.tiles.dev1-1.ApplicationResources"
> null="false">
> </message-resource>
> -->
>
> 3) Made sure I was using the ActionComponentServlet in my web.xml file:
>
>     <servlet-name>action</servlet-name>
>             <!-- Specify servlet class to use
>                   If you also plan to use Struts, use ActionComponentServlet
>
>                   If you don't need Struts, use TilesServlet -->
>
> <servlet-class>org.apache.struts.tiles.ActionComponentServlet</servlet-class
> >
>
> These three steps were the only suggestions I could find on the list.  With
> this configuration I still received the following error when invoking this
> action:
>
> java.lang.IllegalArgumentException: Path site.index.page does not start with
> a "/" character
>
> With Struts 1.1, action forwards calling tile layouts works as advertised.
> The only difference between the two configurations is that the two entries
> in step 2 (ApplicationResources and TilesRequestProcessor) are left in the
> struts-config.xml.
>
> Please let me know if I've missed something with my Struts 1.0
> configuration.
>
> Thanks,
> Eric
>
> > -----Original Message-----
> > From: Cedric Dumoulin [mailto:[EMAIL PROTECTED]]
> > Sent: Tuesday, April 09, 2002 4:27 AM
> > To: Struts Users Mailing List
> > Subject: Re: tiles question
> >
> >
> >
> >   Yes it is ;-)
> >   Have you specify to use the appropriate Tiles processor (if
> > struts1.1) or tiles action servlet (struts1.0.x) ?
> >
> >   In struts1.1, add following to your struts-config file :
> >   <!-- Here we specified the tiles processor -->
> >   <controller
> > processorClass="org.apache.struts.tiles.TilesRequestProcessor">
> >   </controller>
> >
> >   In struts 1.0, specify to use ComponentActionServlet in
> > web.xml. Check documentation or examples.
> >   Other users have already got this problem, check struts
> > archive for "Weird problem with tiles and struts forward".
> >
> >     Hope this help,
> >
> >     Cedric
> >
> > [EMAIL PROTECTED] wrote:
> >
> > > Hi,
> > >
> > > Is it possible to call a tiles layout definition from an
> > action tag in my
> > > struts-config.xml file?
> > >
> > > Here's the tag in my struts-config.xml:
> > >
> > > <action            path="/resources"
> > >                forward="site.resources.page"/>
> > >
> > > Here's the definition in my tiles-defs.xml:
> > >
> > > <definition name="site.resources.page" extends="site.mainLayout" >
> > >       <put name="body"   value="/tiles/resources.jsp" />
> > > </definition>
> > >
> > > When I try to invoke this action forward I get an exception:
> > >
> > > java.lang.IllegalArgumentException: Path site.services.page
> > does not start
> > > with a "/" character
> > >
> > > The forward tag is expecting a value like '/resources.jsp',
> > not a tiles
> > > layout.  Is what I'm trying to do possible?
> > >
> > > Thanks,
> > > Eric.
> > >
> > >
> > **********************************************************************
> > > This message, including any attachments, contains
> > confidential information intended for a specific individual
> > and purpose, and is protected by law.  If you are not the
> > intended recipient, please contact sender immediately by
> > reply e-mail and destroy all copies.  You are hereby notified
> > that any disclosure, copying, or distribution of this
> > message, or the taking of any action based on it, is strictly
> > prohibited.
> > > TIAA-CREF
> > >
> > **********************************************************************
> > >
> > > --
> > > To unsubscribe, e-mail:
> > <mailto:struts-user-> [EMAIL PROTECTED]>
> > > For
> > additional commands,
> > e-mail: <mailto:[EMAIL PROTECTED]>
> >
> >
> > --
> > To unsubscribe, e-mail:
> > <mailto:struts-user-> [EMAIL PROTECTED]>
> > For
> > additional commands,
> > e-mail: <mailto:[EMAIL PROTECTED]>
> >
>
> **********************************************************************
> This message, including any attachments, contains confidential information intended 
>for a specific individual and purpose, and is protected by law.  If you are not the 
>intended recipient, please contact sender immediately by reply e-mail and destroy all 
>copies.  You are hereby notified that any disclosure, copying, or distribution of 
>this message, or the taking of any action based on it, is strictly prohibited.
> TIAA-CREF
> **********************************************************************
>
> --
> To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>


--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to