aspose file tools*
The moose likes Struts and the fly likes  The requested resource (/contactUs.do) is not available. Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Frameworks » Struts
Bookmark " The requested resource (/contactUs.do) is not available. " Watch " The requested resource (/contactUs.do) is not available. " New topic
Author

The requested resource (/contactUs.do) is not available.

soheil amini
Greenhorn

Joined: Apr 06, 2011
Posts: 7
Hi dear friends

I use MyEclipes as IDE and I created a web program project and add struts capabilities on that, the problem is this famous error "The requested resource (/contactUs.do) is not available."
i check all form,action form, strust-config.xml to solve it, but i can't
could you pleas help me to solve it

Action form :



From:



Strust-config.xml :


web.xml (which is in WEB-INF folder in my project):



I also change the action path to "/contactUs.do" and "contactUs.do" and redeployed it, but again not work



---
Shailesh Narkhede
Ranch Hand

Joined: Jul 10, 2008
Posts: 368
Hi Soheil,

are you put struts-config.xml xml in WEB-INF folder, please check name of this file also. how you are calling contactUs.do? are you calling it from any JSP if yes please put that jsp in your post.


Thanks,
Shailesh
soheil amini
Greenhorn

Joined: Apr 06, 2011
Posts: 7

Hi Shailesh
actually i use the MyEclipse as IDE and it automatically do all of it, but i check them often, the struts-config.xml file is in WEB-INF directory and its name is same,
and i call it directly from address bar, means i type http://localhost:8085/contactUs.do and press enter, my tomcat port define in 8085, i change it in server.xml on this line
please help me to find it out, it is very necessary for me
Ankit Garg
Sheriff

Joined: Aug 03, 2008
Posts: 9313
    
  17

Can you check the console output or the logs to see if your application deployed successfully? I'm not too familiar with Struts 1.x but if it requires ActionServlet to be started just as the application starts, then you should set load-on-startup to a positive value, 1 would work just fine...


SCJP 6 | SCWCD 5 | Javaranch SCJP FAQ | SCWCD Links
soheil amini
Greenhorn

Joined: Apr 06, 2011
Posts: 7
When i deployed whit MyEclipse there is no error, i also check the file in tomcat5/webapps folder, but let me know how can i check load-on-startup value is positive value or not ?
Shailesh Narkhede
Ranch Hand

Joined: Jul 10, 2008
Posts: 368
Hi,

Your package for ContactUsForm is below,



and in struts-config.xml you given as below,



In java class it is strust and in struts-config.xml it is struts in package name.

Please correct it & try again.
Aditi agarwal
Ranch Hand

Joined: Feb 23, 2011
Posts: 225
hey soheil amini

just do one thing go to myeclipse menu bar-> help->helpcontents

then on left hand side of new window go to MYEclipse Learning center
->web development->getting started-> struts1.x

here is a sample program just try it running & make your all programs like this in strust further they all will work

 
 
subject: The requested resource (/contactUs.do) is not available.