• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

How to get started with Servlets?

 
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I in a right pickle here. So I hope some one can help me out.
Basically, I want to learn servlets and jsp's as Ive been doing java for a bit now, and want to see what else it can do.
Soooo....i downloaded the j2ee from the sun site, and installed that. And read a bit more and it said i needed a server to run servlets and jsp's - makes sense so far. But, where to go from there? Theres all this stuff about setting the j2ee_home and java_home? I dont understand where. The jarkarta ant server that i downloaded, also has this ant_home thing, where i guess i have to state where it is, but do i have to put all this in the autoexec.bat? or is there somewhere else.
Also, i read something somewhere about an JSDK (java servlet development kit) has this been updated by the j2ee? ie is it the same. As my book says i have to more a servlet.jar file into my jre/lib/ext folder and I dont have a servlet.jar file
If anyone could shed any light on what i should do, i would be more that grateful. I look forward to hearing from you all!
Thanks,
Hannah
 
Ranch Hand
Posts: 63
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
All you need is Tomcat. It is an open source Web Server software from Apache. There are others but this is very popular.This link will give you further info. http://www.webappcabaret.com/javachina/tomcathowto.htm
You can use this to test JSP/Servlets and Javabeans( not to be confused with EJB's)
Of course you can use notepad/wordpad and the JDK.
You can also find out just aboput anything you need by doing a search on this site. It's amazing how people tend to have the same problems.
Cheers and good luck
 
Ranch Hand
Posts: 3695
IntelliJ IDE Java Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
The JSDK was the older Development Kit put out by Sun, to do servlet development. They supported this until they gave up and realized Tomcat was doing a better job than they were.

If you downloaded the j2sdkee from Sun, then you have something called j2ee.jar. This actually contains all the packages in servlet.jar, plus several more.

To do just servlets and JSP though, as Eric mentions, the only thing you need is Tomcat: http://jakarta.apache.org/builds/jakarta-tomcat-4.0/release/v4.0.1/bin/jakarta-tomcat-4.0.1.exe
That is the windows installer version of the latest Tomcat release.

JAVA_HOME
TOMCAT_HOME
- or -
CATALINA_HOME (for Tomcat 4.x)
ANT_HOME

These are all environment variables that you would set up in autoexec.bat (Win9x) or in the System environment variables for WinNT/2k. Get back to us on your OS for more help there.
 
Hannah Redmond
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks guys,
ive downloaded the tomcat program and have it installed, so im just trying to set up all the environments, but i thought id let you know that i have win98, i read somewhere that i might have problems..?
I have to say, i havent had any yet, but then i havent really tried it.
Im sure ill have more q's but thanks for the replies, its much appreciated.
Hannah
 
Hannah Redmond
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
mm, right
i cant seem to get the
J2EE_HOME=c:\j2ee1_3;
JAVA_HOME=c:\JDK1_3_1;
and
TOMCAT_HOME=c:\Tomcat4_0;
to work in my autoexec.bat...
just says bad file name and ignores it.
why?

 
Ranch Hand
Posts: 101
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
because you need to put a command in front of it
I never heard of the JAVA_HOME=c:\fjisdjfo\ command You??
so
set JAVA_HOME=...
method
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
reply
    Bookmark Topic Watch Topic
  • New Topic