netbeans problem

Reply

Join Date: Nov 2004
Posts: 257
Reputation: sam1 is an unknown quantity at this point 
Solved Threads: 1
sam1's Avatar
sam1 sam1 is offline Offline
Posting Whiz in Training

netbeans problem

 
0
  #1
Dec 12th, 2005
hi

does any1 knw how to put the path for servlets in netbeans.

it is located in src/java/controll/servlet

i have this in my code action = "servlet/controll.servlet" but it says directory not found

thanx
ps I posted it here because nobody is answering it in jsp section!! :rolleyes:
Reply With Quote Quick reply to this message  
Join Date: Nov 2004
Posts: 6,143
Reputation: jwenting is just really nice jwenting is just really nice jwenting is just really nice jwenting is just really nice 
Solved Threads: 213
Team Colleague
jwenting's Avatar
jwenting jwenting is offline Offline
duckman

Re: netbeans problem

 
0
  #2
Dec 12th, 2005
What are you trying to accomplish?
I don't have Netbeans installed here (don't like the product, too slow and cumbersome) but you should be able to add the requires jar to compile them like any other.
If you want to have Netbeans generate a web application it should automatically do that for you and set up your web.xml and server environment as well (if Netbeans supports such options, I think it does by now).
As people are clearly allowed to attack me but I'm not allowed to defend myself, I no longer post to this site.
Reply With Quote Quick reply to this message  
Join Date: Nov 2004
Posts: 257
Reputation: sam1 is an unknown quantity at this point 
Solved Threads: 1
sam1's Avatar
sam1 sam1 is offline Offline
Posting Whiz in Training

Re: netbeans problem

 
0
  #3
Dec 12th, 2005
hi

it does everything automatically. I have a page where someone should enter their names, it should read the servlet to display the names or store it. But it does not read the path it says 404 error servlet not found. I think it is something to do with the path name in action, i couldnt figure it out.
Reply With Quote Quick reply to this message  
Join Date: Jan 2006
Posts: 3
Reputation: brcvogt is an unknown quantity at this point 
Solved Threads: 0
brcvogt brcvogt is offline Offline
Newbie Poster

Re: netbeans problem

 
0
  #4
Jan 11th, 2006
Hi,

Have you sorted out your problem? I have a similar problem and it is for my college project. Please let me know if you have managed.

My email is brcvogt@yahoo.com

src/java/Bradshaw/servlet/LoginServlet.java

And the action property in my form tag is as follows:

<form name="Input" action="http://localhost:8084/servlet/Bradshaw.LoginServlet" method="post">

I do not know hot ot do this correctly.

Regards,
Brendan
Reply With Quote Quick reply to this message  
Join Date: Nov 2004
Posts: 6,143
Reputation: jwenting is just really nice jwenting is just really nice jwenting is just really nice jwenting is just really nice 
Solved Threads: 213
Team Colleague
jwenting's Avatar
jwenting jwenting is offline Offline
duckman

Re: netbeans problem

 
0
  #5
Jan 11th, 2006
that would be Bradshaw.servlet.LoginServlet which would need a mapping in your web.xml deployment descriptor as well.
As people are clearly allowed to attack me but I'm not allowed to defend myself, I no longer post to this site.
Reply With Quote Quick reply to this message  
Join Date: Jan 2006
Posts: 3
Reputation: brcvogt is an unknown quantity at this point 
Solved Threads: 0
brcvogt brcvogt is offline Offline
Newbie Poster

Re: netbeans problem

 
0
  #6
Jan 11th, 2006
Thanks for the quick reply!!

In my web.xml file I have the following:

<servlet>
<servlet-name>LoginServlet</servlet-name>
<servlet-class>Bradshaw.servlet.LoginServlet</servlet-class>
</servlet>
<servlet-mapping>
<servlet-name>LoginServlet</servlet-name>
<url-pattern>/LoginServlet</url-pattern>
</servlet-mapping>

Is this correct?

Regards,
Brendan
Reply With Quote Quick reply to this message  
Join Date: Jan 2006
Posts: 3
Reputation: brcvogt is an unknown quantity at this point 
Solved Threads: 0
brcvogt brcvogt is offline Offline
Newbie Poster

Re: netbeans problem

 
0
  #7
Jan 11th, 2006
Still not working, unless if something is wrong in my web.xml file? I've posted this as well. I don't usually work with java, but it's for my college project.

Originally Posted by jwenting
that would be Bradshaw.servlet.LoginServlet which would need a mapping in your web.xml deployment descriptor as well.
Reply With Quote Quick reply to this message  
Join Date: Nov 2004
Posts: 6,143
Reputation: jwenting is just really nice jwenting is just really nice jwenting is just really nice jwenting is just really nice 
Solved Threads: 213
Team Colleague
jwenting's Avatar
jwenting jwenting is offline Offline
duckman

Re: netbeans problem

 
0
  #8
Jan 11th, 2006
given your web.xml mapping you should use /servlet/LoginServlet for the relative URL, nothing more.
As people are clearly allowed to attack me but I'm not allowed to defend myself, I no longer post to this site.
Reply With Quote Quick reply to this message  
Join Date: Oct 2009
Posts: 1
Reputation: violet.shiney is an unknown quantity at this point 
Solved Threads: 0
violet.shiney violet.shiney is offline Offline
Newbie Poster

netbeans problem

 
0
  #9
Oct 11th, 2009
hi..
i m using netbeans 5.whenever i try to run any jsp/servlet /html file in netbeans,an error occurs "port 8084 is already occupied.but in 8084,apache tomcat runs.still the files does not run...
Reply With Quote Quick reply to this message  
Join Date: Dec 2004
Posts: 4,179
Reputation: peter_budo has much to be proud of peter_budo has much to be proud of peter_budo has much to be proud of peter_budo has much to be proud of peter_budo has much to be proud of peter_budo has much to be proud of peter_budo has much to be proud of peter_budo has much to be proud of peter_budo has much to be proud of peter_budo has much to be proud of 
Solved Threads: 481
Moderator
Featured Poster
peter_budo's Avatar
peter_budo peter_budo is offline Offline
Code tags enforcer
 
0
  #10
Oct 11th, 2009
Originally Posted by violet.shiney View Post
hi..
i m using netbeans 5.whenever i try to run any jsp/servlet /html file in netbeans,an error occurs "port 8084 is already occupied.but in 8084,apache tomcat runs.still the files does not run...
You may want to identify what application is running at that port.
Execute
  1. netstat -aon | findstr “8080
(the straight line between two commands on windows will come as two shorter lines over each other)
In my case last data in executed command stands for process ID (PID) was 3016. Next is
  1. tasklist | findstr “3016
this returned java.exe
Click image for larger version

Name:	find_port.png
Views:	0
Size:	9.1 KB
ID:	12076
If you got java as return then you have already running instance of Tomcat and you need to use Administrative Tools >> Services to shut down this instance. In case it is different application you need to configure either application to use different port of NetBeans to open Tomcat on different port
Learn to see in another's calamity the ills which you should avoid.
Publilius Syrus
(~100 BC)

LJC - London Java Community, Graduate & Undergraduate Software Development Community, JAVAWUG (Java Web User Group), The London Android Group
Reply With Quote Quick reply to this message  
Reply

Message:


Thread Tools Search this Thread



About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC