You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Neil Aggarwal <ne...@JAMMConsulting.com> on 2007/02/26 04:34:19 UTC
What to use instead of tiles in Struts2?
Hello:
The tiles plugin for struts2 is labeled experimental.
Is there another way of doing similar functionality on
struts2?
Thanks,
Neil
--
Neil Aggarwal, (214)986-3533, www.JAMMConsulting.com
FREE! Eliminate junk email and reclaim your inbox.
Visit http://www.spammilter.com for details.
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org
Re: What to use instead of tiles in Struts2?
Posted by Dariusz Wojtas <dw...@gmail.com>.
If Tiles is problematical - try Sitemesh.
It will take few hours to learn it and configure (when you do it for
the 2nd time - it takes 30 minutes).
I use it without problems with S2.
I used Tiles in the past, after finding Sitemesh about a year ago I
would never switch back to Tiles. Maybe if produced pages would be
100KB+, but that is quite rare case I think.
Regards
Dariusz Wojtas
On 2/26/07, Neil Aggarwal <ne...@jammconsulting.com> wrote:
> Hello:
>
> The tiles plugin for struts2 is labeled experimental.
>
> Is there another way of doing similar functionality on
> struts2?
>
> Thanks,
> Neil
>
>
> --
> Neil Aggarwal, (214)986-3533, www.JAMMConsulting.com
> FREE! Eliminate junk email and reclaim your inbox.
> Visit http://www.spammilter.com for details.
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org
Re: What to use instead of tiles in Struts2?
Posted by Joe Germuska <jo...@germuska.com>.
On 2/26/07, Ray Clough <ra...@allthisisthat.com> wrote:
>
> I have been unable to get Tiles to load successfully at all, following
> the simple instructions on the web site:
> http://struts.apache.org/2.x/docs/tiles-plugin.html. Are those
> instructions correct/complete? They are incorrect on at least one
> point. The first point mentioned specifies to declare a dependency.
> The example is for Maven. My belief is that this step is ONLY for those
> using Maven, and so it should be labeled that way.
Item one reads "Include the struts-tiles-plugin as a dependency in your web
application. ***If you are using maven2***, the dependency configuration
will be similar to:..."
The fact that you need to depend upon the struts-tiles-plugin is universal,
not only for those using Maven; it's only a question of how one declares the
dependency.
That said, especially while Tiles2 and the plugin are under rapid
development, I would suggest that Maven is by far the best way to keep up
with the front edge of development.
I get various "ClassNotFoundException" messages, depending on which jar
> files are in the WEB-INF/lib directory. Currently I'm getting the
> exception for org.springframework.web.context.ContextLoaderListener. I
> have all the jar files in the "all" distribution, which is:
....
you do not, however, have the Spring Framework jars. I would suggest
REMOVING all of the Struts2 plugins which you are not using, to simplify
things. If you still get ClassNotFoundExceptions, post another message with
the specific class and the current contents of your WEB-INF/lib directory.
Regarding the original question starting this thread, let me point out that
the reason Tiles support is marked "experimental" is because Tiles2 is still
not even in beta release yet. It definitely works, but one must not use it
expecting the kind of stability that fully released software has. The Tiles
developers may be changing the API, tag library, or XML syntax at will until
they are ready to commit to freezing it and making a full release. The best
way to track this progress is to join the "dev@tiles.apache.org" mailing
list.
Joe
> 11/29/2006 08:59 PM 358,273 antlr-2.7.2.jar
> > 11/29/2006 09:00 PM 118,483 commons-beanutils-1.6.jar
> > 11/29/2006 09:00 PM 90,001 commons-chain-1.1.jar
> > 11/29/2006 08:56 PM 38,015 commons-logging-1.0.4.jar
> > 11/29/2006 08:59 PM 119,555 commons-validator-1.3.0.jar
> > 02/25/2007 06:23 PM 0 dirlist.txt
> > 01/29/2007 08:13 AM 802,494 freemarker-2.3.8.jar
> > 02/18/2007 05:19 PM 168,081 ognl-2.6.11.jar
> > 11/29/2006 09:00 PM 65,261 oro-2.0.8.jar
> > 02/04/2007 09:47 PM 319,406 struts-core-1.3.5.jar
> > 02/18/2007 09:02 PM 10,550
> struts2-codebehind-plugin-2.0.6.jar
> > 02/18/2007 09:02 PM 24,320
> > struts2-config-browser-plugin-2.0.6.jar
> > 02/18/2007 09:00 PM 2,195,521 struts2-core-2.0.6.jar
> > 02/18/2007 09:02 PM 14,854
> > struts2-jasperreports-plugin-2.0.6.jar
> > 02/18/2007 09:02 PM 8,484
> struts2-jfreechart-plugin-2.0.6.jar
> > 02/18/2007 09:02 PM 27,008 struts2-jsf-plugin-2.0.6.jar
> > 02/18/2007 09:02 PM 8,741
> > struts2-pell-multipart-plugin-2.0.6.jar
> > 02/18/2007 09:02 PM 15,247 struts2-plexus-plugin-2.0.6.jar
> > 02/18/2007 09:02 PM 35,880
> struts2-sitegraph-plugin-2.0.6.jar
> > 02/18/2007 09:02 PM 13,909 struts2-sitemesh-plugin-2.0.6.jar
> > 02/18/2007 09:03 PM 8,156 struts2-spring-plugin-2.0.6.jar
> > 02/18/2007 09:03 PM 25,050 struts2-struts1-plugin-2.0.6.jar
> > 02/18/2007 09:03 PM 15,139 struts2-tiles-plugin-2.0.6.jar
> > 02/11/2007 07:06 PM 22,360
> tiles-api-2.0-20070207.130156-4.jar
> > 02/11/2007 07:06 PM 137,187
> > tiles-core-2.0-20070207.130156-4.jar
> > 02/18/2007 05:19 PM 452,600 xwork-2.0.1.jar
>
> If I add the spring jars, I get exceptions for other classes.
>
> I specified the following config-param in web.xml
>
> <!-- Specify the definitions file for Tiles. This is not specified
> on the Struts web site. -->
> <context-param>
> <param-name>tilesDefinitions</param-name>
> <param-value>/WEB-INF/tiles.xml</param-value>
> </context-param>
>
> I added the following to struts.xml
> <!--
> All package definitions which require tiles support must
> either
> extend the tiles-default package or must register the Tiles
> Result type definition.
> -->
> <result-types>
> <result-type name="tiles"
> class="org.apache.struts2.views.tiles.TilesResult"/>
> </result-types>
>
> ...... The StrutsTileListener is added _after_ the ContextLoaderListener.
> > <listener>
> > <listener-class>
> > org.apache.struts2.tiles.StrutsTilesListener
> > </listener-class>
> > </listener>
> >
> The servlet container (Tomcat 5.5) throws the exceptions mentioned above
> during the load process. Please, I need advice. I have long contended
> that Tiles is the niftiest piece of Struts, and I can't see using
> Struts-2 without Tiles.
>
> Thanks,
> - Ray Clough
> ray@allthisisthat.com
>
>
>
>
> Dave Newton wrote:
> > --- Neil Aggarwal <ne...@JAMMConsulting.com> wrote:
> >
> >> Is there another way of doing similar functionality
> >> on struts2?
> >>
> >
> > A lot can be done with the <s:action.../> tag.
> >
> > That said, I have had essentially zero problems with
> > the Tiles plugin and have been using it successfully
> > for some months now.
> >
> > d.
> >
> >
> >
> >
> >
> ____________________________________________________________________________________
> > Never miss an email again!
> > Yahoo! Toolbar alerts you the instant new Mail arrives.
> > http://tools.search.yahoo.com/toolbar/features/mail/
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
> > For additional commands, e-mail: user-help@struts.apache.org
> >
> >
> >
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
> For additional commands, e-mail: user-help@struts.apache.org
>
>
--
Joe Germuska
Joe@Germuska.com * http://blog.germuska.com
"The truth is that we learned from João forever to be out of tune."
-- Caetano Veloso
Re: What to use instead of tiles in Struts2?
Posted by Ray Clough <ra...@allthisisthat.com>.
I have been unable to get Tiles to load successfully at all, following
the simple instructions on the web site:
http://struts.apache.org/2.x/docs/tiles-plugin.html. Are those
instructions correct/complete? They are incorrect on at least one
point. The first point mentioned specifies to declare a dependency.
The example is for Maven. My belief is that this step is ONLY for those
using Maven, and so it should be labeled that way.
I get various "ClassNotFoundException" messages, depending on which jar
files are in the WEB-INF/lib directory. Currently I'm getting the
exception for org.springframework.web.context.ContextLoaderListener. I
have all the jar files in the "all" distribution, which is:
> 11/29/2006 08:59 PM 358,273 antlr-2.7.2.jar
> 11/29/2006 09:00 PM 118,483 commons-beanutils-1.6.jar
> 11/29/2006 09:00 PM 90,001 commons-chain-1.1.jar
> 11/29/2006 08:56 PM 38,015 commons-logging-1.0.4.jar
> 11/29/2006 08:59 PM 119,555 commons-validator-1.3.0.jar
> 02/25/2007 06:23 PM 0 dirlist.txt
> 01/29/2007 08:13 AM 802,494 freemarker-2.3.8.jar
> 02/18/2007 05:19 PM 168,081 ognl-2.6.11.jar
> 11/29/2006 09:00 PM 65,261 oro-2.0.8.jar
> 02/04/2007 09:47 PM 319,406 struts-core-1.3.5.jar
> 02/18/2007 09:02 PM 10,550 struts2-codebehind-plugin-2.0.6.jar
> 02/18/2007 09:02 PM 24,320
> struts2-config-browser-plugin-2.0.6.jar
> 02/18/2007 09:00 PM 2,195,521 struts2-core-2.0.6.jar
> 02/18/2007 09:02 PM 14,854
> struts2-jasperreports-plugin-2.0.6.jar
> 02/18/2007 09:02 PM 8,484 struts2-jfreechart-plugin-2.0.6.jar
> 02/18/2007 09:02 PM 27,008 struts2-jsf-plugin-2.0.6.jar
> 02/18/2007 09:02 PM 8,741
> struts2-pell-multipart-plugin-2.0.6.jar
> 02/18/2007 09:02 PM 15,247 struts2-plexus-plugin-2.0.6.jar
> 02/18/2007 09:02 PM 35,880 struts2-sitegraph-plugin-2.0.6.jar
> 02/18/2007 09:02 PM 13,909 struts2-sitemesh-plugin-2.0.6.jar
> 02/18/2007 09:03 PM 8,156 struts2-spring-plugin-2.0.6.jar
> 02/18/2007 09:03 PM 25,050 struts2-struts1-plugin-2.0.6.jar
> 02/18/2007 09:03 PM 15,139 struts2-tiles-plugin-2.0.6.jar
> 02/11/2007 07:06 PM 22,360 tiles-api-2.0-20070207.130156-4.jar
> 02/11/2007 07:06 PM 137,187
> tiles-core-2.0-20070207.130156-4.jar
> 02/18/2007 05:19 PM 452,600 xwork-2.0.1.jar
If I add the spring jars, I get exceptions for other classes.
I specified the following config-param in web.xml
<!-- Specify the definitions file for Tiles. This is not specified
on the Struts web site. -->
<context-param>
<param-name>tilesDefinitions</param-name>
<param-value>/WEB-INF/tiles.xml</param-value>
</context-param>
I added the following to struts.xml
<!--
All package definitions which require tiles support must either
extend the tiles-default package or must register the Tiles
Result type definition.
-->
<result-types>
<result-type name="tiles"
class="org.apache.struts2.views.tiles.TilesResult"/>
</result-types>
...... The StrutsTileListener is added _after_ the ContextLoaderListener.
> <listener>
> <listener-class>
> org.apache.struts2.tiles.StrutsTilesListener
> </listener-class>
> </listener>
>
The servlet container (Tomcat 5.5) throws the exceptions mentioned above
during the load process. Please, I need advice. I have long contended
that Tiles is the niftiest piece of Struts, and I can't see using
Struts-2 without Tiles.
Thanks,
- Ray Clough
ray@allthisisthat.com
Dave Newton wrote:
> --- Neil Aggarwal <ne...@JAMMConsulting.com> wrote:
>
>> Is there another way of doing similar functionality
>> on struts2?
>>
>
> A lot can be done with the <s:action.../> tag.
>
> That said, I have had essentially zero problems with
> the Tiles plugin and have been using it successfully
> for some months now.
>
> d.
>
>
>
>
> ____________________________________________________________________________________
> Never miss an email again!
> Yahoo! Toolbar alerts you the instant new Mail arrives.
> http://tools.search.yahoo.com/toolbar/features/mail/
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
> For additional commands, e-mail: user-help@struts.apache.org
>
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org
Re: What to use instead of tiles in Struts2?
Posted by Dave Newton <ne...@yahoo.com>.
--- Neil Aggarwal <ne...@JAMMConsulting.com> wrote:
> Is there another way of doing similar functionality
> on struts2?
A lot can be done with the <s:action.../> tag.
That said, I have had essentially zero problems with
the Tiles plugin and have been using it successfully
for some months now.
d.
____________________________________________________________________________________
Never miss an email again!
Yahoo! Toolbar alerts you the instant new Mail arrives.
http://tools.search.yahoo.com/toolbar/features/mail/
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org