Java 2 Enterprise Edition (J2EE)
a) Software Required:
· Web Server
· Apache Tomcat Server 6.0
· Web Server
· Apache Tomcat Server 6.0
b) Steps for installing Apache Tomcat:
· Go to the link : http://tomcat.apache.org/download-60.cgi#6.0.20
· Run the file : “apache-tomcat-6.0.20.exe”
· Follow the instruction for installation.
· Copy the file called “com.sysdeo.eclipse.tomcat_3.2.1” from the Tomcat folder and paste it inside the plugins folder under the eclipse where the eclipse is installed.
· For the installation of Tomcat server 6.0 refer the link: http://www.roseindia.net/web-application-server/tomcat/install-configure.shtml
· Go to the WINDOWS tab in the Menu bar and select "Preferences"
· Select "server" option on the left of the window and add the "Tomcat Installation Directories path" in the option provided.
For example if the Apache Tomcat server is installed in the directory “D:” then, The Environment variables are set as follows.
· How to configure Tomcat server in Eclipse?
Here i have taken an example of the configuring the “Apache Tomcat version 5.5”, in this example the Tomcat server is installed in the “C:\” directory.
· How to create a Web application in eclipse?
· How to create servlet?
Example: If the following code is written in the index.jsp (Created as mentioned earlier)
"GreetingServlet"
method=
"POST"
>
First Name:
"text"
name=
"firstName"
size=
"20"
>
Surname:
"text"
name=
"surname"
size=
"20"
>
"submit"
value=
"Submit"
>
When we run the index.jsp on server , The following page will be seen
On Clicking the “Submit” button the following page will be seen