| Author |
Struts example trouble
|
Gail Mikels
Ranch Hand
Joined: May 07, 2001
Posts: 634
|
|
I'm trying to get an idea of what Struts is by running Thomas Paul's examples. I thought I'd followed the instructions properly, but after 2 installation attempts I can't even get a test index page to appear from the struts directory, much less the example, which makes me think I've set up the environment wrong (plus the fact that I'm environment-impaired). I've obviously either missed something, or just don't understand. Here's my directory structure & struts-config.xml. Where have I gone horribly wrong? Many Thanks!
|
Gail Mikels
|
 |
Kedar Dravid
Ranch Hand
Joined: May 28, 2004
Posts: 333
|
|
|
What error message are u getting?
|
 |
Gail Mikels
Ranch Hand
Joined: May 07, 2001
Posts: 634
|
|
Sorry 'bout that. I don't get any message in the console window, but the browser gives me "The requested resource (/struts/jsp/index.jsp) is not available", or "The requested resource (/struts/jsp/LoginView.jsp) is not available." Any help? Thanks! [ October 18, 2004: Message edited by: Elaine Micheals ]
|
 |
Gail Mikels
Ranch Hand
Joined: May 07, 2001
Posts: 634
|
|
Ok - I just noticed that I do get an error in my log file... Does anyone know what this means? I have not been able to hunt it down.
|
 |
Jason Menard
Sheriff
Joined: Nov 09, 2000
Posts: 6450
|
|
|
Your ActionServlet isn't loading. My guess is that there may be a problem with your web.xml.
|
Jason's Blog
|
 |
Gail Mikels
Ranch Hand
Joined: May 07, 2001
Posts: 634
|
|
Hmmmm... I noticed that my web.xml has a tablib entry for struts-template, but I don't have a file by that name. I tried taking out the entry, but got the same error on restarting the server. It's not in my download package... do you know what that's all about? Here's my web.xml... Many Thanks
|
 |
Kedar Dravid
Ranch Hand
Joined: May 28, 2004
Posts: 333
|
|
|
If nothing else works, try reinstalling Tomcat. It is a fairly non-intrusive procedure.
|
 |
Jason Menard
Sheriff
Joined: Nov 09, 2000
Posts: 6450
|
|
Originally posted by Elaine Micheals: Hmmmm... I noticed that my web.xml has a tablib entry for struts-template, but I don't have a file by that name.
The struts template taglib was in version 1.0 of Struts. It has been deprecated (and removed maybe?) and replaced by Tiles.
|
 |
Gail Mikels
Ranch Hand
Joined: May 07, 2001
Posts: 634
|
|
AH - HA!!! In the first part of the 1.0 tutorial, it suggests copying struts.jar & servlet.jar into your java directory's jre\lib\ext directory. Apparently this is a no-no. Remove them, & it runs fine!! :-) Yay!
|
 |
 |
|
|
subject: Struts example trouble
|
|
|