aspose file tools
The moose likes Struts and the fly likes Deploy Strut2 application using Netbeans 6.8 Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login
JavaRanch » Java Forums » Frameworks » Struts
Reply Bookmark "Deploy Strut2 application using Netbeans 6.8" Watch "Deploy Strut2 application using Netbeans 6.8" New topic
Author

Deploy Strut2 application using Netbeans 6.8

Nicola Ace
Greenhorn

Joined: Sep 27, 2010
Posts: 8
Hello guys i'm tring to deploy my 1st struct2 applicaion but i'm having very big problems...
I'm using Apache 6.0 and netbeans 6.8
Hope someone can help me.

My web.xml file is(is set under WEB-INF) :



My struts.xml is (is set under src)



Under src/actions i have my action java file (named VerySimpleAction.java)


now i want to show the resoult calling the verysimple.jsp page



My struts 2 libraries are:
commons-fileupload-1-2-1.jar
commons.io-1.3.2.jar
commons-logging-1.1.1.jar
freemarker-2.3.16.jar
javassist.jar
ognl-3.0.jar
struts2-core-2.2.1.jar
xwork-core-2.2.1..jar

If i'm correct my application should show me : VERY SIMPLE
The problem is that i'm not getting this message but i get HELLO WORLD, the message is written in the default index.jsp that i'm not calling (i think)
Can someone PLEASE give me some hint?

Tanx a lot!!!
Ankit Garg
Saloon Keeper

Joined: Aug 03, 2008
Posts: 9189
    
    2

The name of the framework is Struts not struct. If you have actually named your xml as struct.xml, you need to change it. Also what is the URL that you are entering in the browser??


SCJP 6 | SCWCD 5 | Javaranch SCJP FAQ | SCWCD Links
Nicola Ace
Greenhorn

Joined: Sep 27, 2010
Posts: 8
Sorry it was my mistake. The XML file is named struts.xml.

Ankit Garg wrote: Also what is the URL that you are entering in the browser??


Generally i start the application usung the button "Start Main Project" after having done "Clean and Build".
The call in the browser is this one: http://localhost:8084/Struct2Example1/

My tomcat is listening on 8084

So, can you give me some hints?
Ankit Garg
Saloon Keeper

Joined: Aug 03, 2008
Posts: 9189
    
    2

Well you'll have to enter the action name in the URL to be able to access it. Try this URL
http://localhost:8084/Struct2Example1/VerySimpleAction.action
Nicola Ace
Greenhorn

Joined: Sep 27, 2010
Posts: 8
Very kind, now it works!!
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Deploy Strut2 application using Netbeans 6.8
 
Similar Threads
Need Help - Struts2 s:select issue - Urgent
Struts2 config error
Struts2 Filter and Includes
Struts2 with RAD7
Struts2 with RAD7