Saturday, August 2, 2008

Jsp under Windows runtime environment configuration

Configuration before the preparatory work:

Name names install software download Address
J2sdk j2sdk-1_4_2-windows-i586.exe http://java.sun.com/
Jakarta-Tomcat jakarta-tomcat-5.0.28.zip http://jakarta.apache.org/
Apache-Tomcat

J2sdk the installation and configuration:

1. Computer I / Properties / Advanced / system environment variables / path
And "E: \ j2sdk1.4.2 \ bin";

2. Computer I / Properties / Advanced / system environment variables / JAVA_HOME
And "E: \ j2sdk1.4.2";

3. Computer I / Properties / Advanced / system environment variables / classpath
And "E: \ j2sdk1.4.2 \ lib \ dt.jar; d: \ j2sdk142 \ lib \ tools.jar; d: \ j2sdk142 \ lib;.";
Attention behind that point, it said that the current directory, the directory contains, we can go to any directory needed for the implementation of a directory of the Java programming;

4. Type javac command prompt, there are parameters that suggested that the successful installation.

Tomcat installation and configuration:

1. Will jakarta-tomcat-5.0.28.zip decompress the file E: \ directory tomcat

2. Computer I / Properties / Advanced / system environment variables / TOMCAT_HOME
And "E: \ tomcat";

3. Computer I / Properties / Advanced / system environment variables / CATALINA_HOME
And "E: \ tomcat";

4. Start tomcat: Go to the "D: \ TomCat \ jakarta-tomcat-5.0.5 \ bin \" Double-click startup.bat start Tomcat directory services (double-click shutdown.bat closed Tomcat services);

5. Input http://localhost:8080 a Tomcat welcome the interface;

6. Inspection environment variable configuration:
Prepared with a notepad time.jsp
<% @ Page contentType = "text / html; charset = GB2312"%>
<% @ Page import = "java.util .*"%>
  


Now is the time:
<% Date date = new Date (); %>
<= Date%%>


The time.jsp stored in the document: E: \ tomcat \ webapps \ ROOT directory, enter http://localhost:8080/time.jsp
Occur:
Now is the time: XXXXXXXX (your computer on the current time)
Tomcat configuration so successful.

Tomcat oracle9i default port and conflict resolution:

The first open oracle imports of services will oralce http://localhost:8080 the Oracle Servlet Engine pages.

A revised tomcat port:

In E: \ tomcat \ conf \ server.xml found:
……

No comments: