running servlets ?
I have just started learning servlets. I have J2EE installed on my
machine. Will it be enough to run Servlets or do I need to install
Servlet development kit and stuff like that..
Any help is greatly appreciated.
Re: running servlets ?
Satya Atluri <email@example.com> wrote:
>I have just started learning servlets. I have J2EE installed on my
>machine. Will it be enough to run Servlets or do I need to install
>Servlet development kit and stuff like that..
>Any help is greatly appreciated.
I've also just started learning servlets. I also installed J2EE along with
Here is what I've learned by using the included stuff from Sun:
TO RUN(compile) A JSP PAGE, you have to have run a batch file located in:
You'll see the following message appear in the command prompt, "J2EE server
When you create new JSPs, simply put them in the C:\j2sdkee1.2\public_html\
directory, then open up any web browser and type: http://localhost:8000/<jsp
filename>, it'll take a few seconds to compile the JSP page into a Servlet,
then voila, you get your results.
TO RUN A SERVLET, you have to run a different batch file that comes with
the JSDK (don't confuse this with the J2SDK - two completely different installs)
which is located at C:\jsdk2.1\startserver.bat
You should then see the following message appear in another command prompt:
"JSDK WebServer Version
Loaded configuration fr
endpoint created: :8080"
Any servlets (class files) that you compile and create, you want to place
them in the following directory - C:\jsdk2.1\webpages\Web-inf\servlets\ directory.
After doing that, you can then open your browser and type the following
URL in: http://localhost:8080/servlet/<servlet name - AKA class file name>
I hope this is helpful to somebody. Is it just me, or does it seem like
quite a bit of hoops to jump through to test "simple" stuff? It was a trial
and error process to learn how to do the above stuff.
-- Android Development Center
-- Cloud Development Project Center
-- HTML5 Development Center
-- Windows Mobile Development Center