Environment construction
JDK7.0
Tomcat7.0
MyEclispse10
Tomcat Server
It's Apache's Open source project.
Jsp/servlet container
Set environment variables: Create a new catalina_home to enter the Tomcat address.
Test the browser output: http://localhost:8080/Remember to start the server in the bin directory beforehand.
Tomcat directory Structure
/bin stores the command to start and stop Tomcat.
/conf store various configuration files.
/lib store various drive jar packages
/logs Storing log files
/temp Running temporary files
/webapps default in this file when publishing an application
/work Tomcat places JSP-generated servlets in this directory
To manually establish a Web program step:
Create a project directory in WebApps---> Write index.jsp---> Create web-inf directory---> Test run.
Create a new MyHome folder,
Enter MyHome new index.jsp,
New Web-inf Directory
Create a new Web. XML, classes, and Lib folders.
Test: http://localhost:8080/myhome/index.jsp
Web-info Catalogue Details:
1.web-info is a secure directory for Java WEB applications. Clients cannot access only the server.
2.web.xml is the deployment file for the project.
3.classes folder for placing *.class files.
4.lib folder for storing the required jar packages.
Set welcome page in Web. XML, default is index.jsp
<welcome-file-list>
<welcome-file>/haha.jsp</welcom-file>
</welcome-file-list>
Installation MyEclipse after the direct installation of the inside there is a crack method.
After the installation hack is finished, configure the MyEclipse:
Windows->preference->java->installed JREs find ourselves, not using the default.
To associate with Tomcat:
Windows->preference->servers->tomcat-> Select tomcat7.x for the configuration, and do not forget to change the JDK version of Tomcat after it is finished.
What is a Web virtual path? MyEclipse How do I modify a virtual path?
For example we create a new item Myfirstwebapp and configure it. Browser input http://localhost:8080/MyFirstWebApp/index.jsp This is the virtual path. So how to change
What about this virtual path? In MyEclipse right click on the project Select Properties->myeclipse->web to change.
Modifying the Tomcat default port number must have been modified in the Tomcat configuration file. (/conf/server.xml)
Found it
<connector port= "8080" protocol= "http/1.1"
connectiontimeout= "20000"
redirectport= "8443"/>
You can then modify the properties.
Web development environment Setup and configuration