• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

I encounter Errors when using struts tiles on JSP.

 
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Greetings,
i tried to use tiles and tld files on a jsp page,but i encounter an error while trying to load the jsp file.

These are the libraries i insert into the WEB-INF/lib folder
struts.jar, struts-tiles.tld, struts-nested.tld, struts-logic.tld, struts-html.tld, struts-bean.tld, struts-el.jar, struts-bean.tld, jstl.jar, c.tld, c-rt.tld

My jsp which i'm using:


The errors i encounter:



I will like to ask what have i miss or what do i need to configure to solve this error?

Thanks for the guidance
 
Author
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Have you defined the attributes you're inserting? Are you using a Tiles request processor or otherwise initializing Tiles (IIRC it has a couple mechanisms for doing so)?
 
Lee chaolan
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Ok.. How do i initialise the attributes.

I'm sorry if you feel that my questions are stupid because this is the first time i'm using struts and i'm learning how to use the tiles.

Actually what i'm currently doing is after creating the header.jsp, the footer.jsp and the register.jsp for the body, i decide to dunp all 3 of them into the DefaultLayout.jsp.

So i start my jboss, and type http://localhost:8080/DefaultLayout.jsp to view the page on my browser. At this point, am i on the right track?

Thanks
 
David Newton
Author
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
A few questions/comments:

- There are no stupid questions (for the most part ;)

- What version of Struts are you using? Are you sure you have all the necessary dependencies? The list of JAR files you include seems a little short; I'm almost positive you'll need things like commons-digester and so on.

- Do you have any tiles definition files? Have you looked at the Tiles documentation for how to use Tiles (or other resource)?

- The Struts TLD files shouldn't be in /WEB-INF/lib; they should be in the Struts jar file and you shouldn't need to reference them anywhere, assuming you're using a relatively recent version of Struts and any reasonable app server.
 
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,
I'm using Struts 1.2.9.

i have add in a few more libraries.
commons-beanutils.jar, commons-digester.jar, commons-digester.jar, commons-logging.jar, commons-resources.jar, jakarta-oro.jar, commons-validator.jar

This is my tile-def.xml

 
Lee chaolan
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks..

i finally know whats the error. i cannot directly type the url of the page on the browser. I need to activate struts to display out the tiles.

Thanks for the help.
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic