This week's book giveaway is in the Agile and other Processes forum.
We're giving away four copies of The Mikado Method and have Ola Ellnestam and Daniel Brolund on-line!
See this thread for details.
The moose likes Struts and the fly likes Unable to translate jsp with struts-html taglib Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login


Win a copy of The Mikado Method this week in the Agile and other Processes forum!
JavaRanch » Java Forums » Frameworks » Struts
Reply Bookmark "Unable to translate jsp with struts-html taglib" Watch "Unable to translate jsp with struts-html taglib" New topic
Author

Unable to translate jsp with struts-html taglib

Rade Treci
Greenhorn

Joined: Apr 03, 2009
Posts: 10
Hi everyone!
First I hope that the question is within the standards of the forum.

As for the problem per se,

I'm using Tomcat6.0.18, Eclipse3.4, jdk1.5. It seems tomcat cannot interpret correctly the html struts tag, although it seems that I have set the <taglib-location> pointing to the correct uri.

In my web.xml:

In my whatever.jsp:

And my StackTrace!


In the jsp I tried already moving the taglib to the first line: DID NOT WORK
Changed the uri in the taglib to, http://struts.apache.org/tags-html : DID NOT WORK
Tried pointing the uri directly to the tld file: DID NOT WORK

By the way also <html:radio> tag seems to have problems getting translated, so I suppose that all html:XXXX tags will end up the same. At the moment I haven't tested other struts taglibs (like logic or bean) but I guess the same would happen...

Right now I have no more ideas and any pointer would be deeply appreciated.

Thank you,
Ankit Garg
Saloon Keeper

Joined: Aug 03, 2008
Posts: 9189
    
    2

By looking at the error, I think the error is because request.getAttribute return Object while it is expecting a String there. Use a type cast or a toString call like this...



SCJP 6 | SCWCD 5 | Javaranch SCJP FAQ | SCWCD Links
Rade Treci
Greenhorn

Joined: Apr 03, 2009
Posts: 10
I forgot to mention that this works using JDeveloper and OC4J app server (need to make it work in Eclipse and Tomcat). I would like to make it work with minimum code changes (hopefully none, because there is a LOT to change). I just hope that this is a config problem.
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 56191
    
  13

Please be sure to ask Struts questions in the Struts forum. I have moved this post there for you.


[Smart Questions] [JSP FAQ] [Books by Bear] [Bear's FrontMan] [About Bear]
Rade Treci
Greenhorn

Joined: Apr 03, 2009
Posts: 10
OK thanks
 
I agree. Here's the link: http://ej-technologies/jprofiler - if it wasn't for jprofiler, we would need to run our stuff on 16 servers instead of 3.
 
subject: Unable to translate jsp with struts-html taglib
 
Similar Threads
struts 1.2 problem
Struts JSP exception
javax.servlet.jsp.JspException in Application
javax.servlet.jsp.JspException: Cannot create rewrite URL: java.net.MalformedURLException:
JBoss 5.1 throwing error for missing jsp files in /WEB-INF folder