You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by André Henke <a_...@gmx.de> on 2007/04/19 08:44:28 UTC
tiles2 with struts1
hi,
is there a way to get struts1 work with tiles2?
I'm migrating my application to struts2/tiles2 but there is still struts1 code using tiles forwards which must be supported.
So i have to share the tiles.xml with struts1 TilesPlugin and struts2 StrutsTilesListener.
web.xml
<code>
<listener> <listener-class>org.apache.struts2.tiles.StrutsTilesListener</listener-class>
</listener>
</code>
tiles.xml (tiles-2.0.1)
<code>
<!DOCTYPE tiles-definitions PUBLIC
"-//Apache Software Foundation//DTD Tiles Configuration 2.0//EN"
"http://tiles.apache.org/dtds/tiles-config_2_0.dtd">
<tiles-definitions>
<definition name=".base" template="/layout.jsp">
<put-attribute name="title" value=""/>
<put-attribute name="body" value=""/>
<put-attribute name="navigation" value=".navigation"/>
</definition>
.....
</code>
struts1 struts-config.xml
<code>
<plug-in className="org.apache.struts.tiles.TilesPlugin">
<set-property property="definitions-config" value="/WEB-INF/tiles.xml" />
<set-property property="definitions-debug" value="0" />
<set-property property="definitions-parser-details" value="0" />
<set-property property="definitions-parser-validate" value="false" />
<set-property property="moduleAware" value="true" />
</plug-in>
</code>
Any suggestions? - thanks
André
--
"Feel free" - 10 GB Mailbox, 100 FreeSMS/Monat ...
Jetzt GMX TopMail testen: http://www.gmx.net/de/go/topmail
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org
Re: tiles2 with struts1
Posted by Antonio Petrelli <an...@gmail.com>.
2007/4/19, "André Henke" <a_...@gmx.de>:
> hi antonio,
>
> thanks for this info, but maven build fails after:
> >svn checkout http://svn.apache.org/repos/asf/struts/struts1/trunk
> >mvn install
You're right, it is a known issue (see the comments):
http://issues.apache.org/struts/browse/STR-3017
I hope that this will be fixed with the release of Tiles 2.0.3
Antonio
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org
Re: tiles2 with struts1
Posted by André Henke <a_...@gmx.de>.
hi antonio,
thanks for this info, but maven build fails after:
>svn checkout http://svn.apache.org/repos/asf/struts/struts1/trunk
>mvn install
Output:
D:\Projects\src\20070419-struts1\trunk\tiles2>d:\ProgramFiles\maven-2.0.6\bin\mv
n install
[INFO] Scanning for projects...
[INFO] -------------------------------------------------------------------------
---
[INFO] Building Struts - Tiles 2 integration
[INFO] task-segment: [install]
[INFO] -------------------------------------------------------------------------
---
[INFO] [resources:resources]
[INFO] Using default encoding to copy filtered resources.
Downloading: http://repo1.maven.org/maven2/commons-logging/commons-logging-api/1
.1/commons-logging-api-1.1.pom
[INFO] [compiler:compile]
[INFO] Compiling 11 source files to D:\Projects\src\20070419-struts1\trunk\tiles
2\target\classes
[INFO] ------------------------------------------------------------------------
[ERROR] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Compilation failure
D:\Projects\src\20070419-struts1\trunk\tiles2\src\main\java\org\apache\struts\ti
les2\actions\TilesAction.java:[32,24] cannot find symbol
symbol : class AttributeContext
location: package org.apache.tiles
D:\Projects\src\20070419-struts1\trunk\tiles2\src\main\java\org\apache\struts\ti
les2\actions\TilesAction.java:[99,8] cannot find symbol
symbol : class AttributeContext
location: class org.apache.struts.tiles2.actions.TilesAction
D:\Projects\src\20070419-struts1\trunk\tiles2\src\main\java\org\apache\struts\ti
les2\preparer\ActionPreparer.java:[25,24] cannot find symbol
symbol : class AttributeContext
location: package org.apache.tiles
D:\Projects\src\20070419-struts1\trunk\tiles2\src\main\java\org\apache\struts\ti
les2\preparer\ActionPreparer.java:[52,12] cannot find symbol
symbol : class AttributeContext
location: class org.apache.struts.tiles2.preparer.ActionPreparer
D:\Projects\src\20070419-struts1\trunk\tiles2\src\main\java\org\apache\struts\ti
les2\preparer\UrlPreparer.java:[29,24] cannot find symbol
symbol : class AttributeContext
location: package org.apache.tiles
D:\Projects\src\20070419-struts1\trunk\tiles2\src\main\java\org\apache\struts\ti
les2\preparer\UrlPreparer.java:[46,12] cannot find symbol
symbol : class AttributeContext
location: class org.apache.struts.tiles2.preparer.UrlPreparer
D:\Projects\src\20070419-struts1\trunk\tiles2\src\main\java\org\apache\struts\ti
les2\actions\TilesAction.java:[69,8] cannot find symbol
symbol : class AttributeContext
location: class org.apache.struts.tiles2.actions.TilesAction
D:\Projects\src\20070419-struts1\trunk\tiles2\src\main\java\org\apache\struts\ti
les2\actions\TilesAction.java:[69,59] cannot find symbol
symbol : method getAttributeContext(javax.servlet.http.HttpServletRequest,javax
.servlet.http.HttpServletResponse)
location: interface org.apache.tiles.TilesContainer
[INFO] ------------------------------------------------------------------------
[INFO] For more information, run Maven with the -e switch
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 4 seconds
[INFO] Finished at: Thu Apr 19 12:09:22 CEST 2007
[INFO] Final Memory: 5M/9M
[INFO] ------------------------------------------------------------------------
greetings
André
-------- Original-Nachricht --------
Datum: Thu, 19 Apr 2007 08:55:40 +0200
Von: "Antonio Petrelli" <an...@gmail.com>
An: "Struts Users Mailing List" <us...@struts.apache.org>
Betreff: Re: tiles2 with struts1
> 2007/4/19, "André Henke" <a_...@gmx.de>:
> > hi,
> >
> > is there a way to get struts1 work with tiles2?
> >
> > I'm migrating my application to struts2/tiles2 but there is still
> struts1 code using tiles forwards which must be supported.
>
> The Struts 1 - Tiles 2 integration code is in the trunk of the
> Subversion repository. From my tests, it seems to be pretty stable,
> though it is not released.
>
> Antonio
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
> For additional commands, e-mail: user-help@struts.apache.org
--
"Feel free" - 10 GB Mailbox, 100 FreeSMS/Monat ...
Jetzt GMX TopMail testen: http://www.gmx.net/de/go/topmail
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org
Re: tiles2 with struts1
Posted by Antonio Petrelli <an...@gmail.com>.
2007/4/19, "André Henke" <a_...@gmx.de>:
> hi,
>
> is there a way to get struts1 work with tiles2?
>
> I'm migrating my application to struts2/tiles2 but there is still struts1 code using tiles forwards which must be supported.
The Struts 1 - Tiles 2 integration code is in the trunk of the
Subversion repository. From my tests, it seems to be pretty stable,
though it is not released.
Antonio
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org