Tomcat environment configuration and first JSP program implementation configuration Tomcat bad configuration
1.java_home: The installation directory for the JAVA JDK only (the previous level of the bin directory) F:\JDK7
2.catalina_home: The installation directory with a value of Tomcat G:\Tomcat\apache-tomcat-7.0.79
The first JSP program is ready to work
1. Download the installation MyEclipse and transfer the original eclipse configuration to MyEclipse
Eclipse:file-->export-->general-->preferences-->export all--> fill out which folder to export to
Myeclipse:file-->import-->general-->preferences-->import all--> to enter the saved file
2. Create a Web project, where Src is the folder where the source code is placed, Webboot is the page of the page, and the two folders under that directory cannot change its name
3. Open JSP file, the default visual interface for the upper and lower interface, accustomed to the pure Code interface can be set up: Right-click Index.jsp->open witn-> Select MyEclipse JSP Editor; Unified Settings:window-> Preferences->general->ediors->file associations-> above Select *.jsp-> Select MyEclipse jsp editor-> Select the Default->ok on the right
4. Set the Encoding method:window-> search Jsp->jsp->encoding-> Select Utf-8
Access to JSP programs via browser (methods vary)
1. After opening the Tomcat installation directory->conf->server.xml-> open, enter (line 4th) XML statement at the end: <context path= "/text" docbase= "F:\My Eclipes\workspace\text\webroot "(Path to JSP file) reloadable=" true "/><context path="/text docbase=jsp file path, To its Webroot directory reloadable= "Ture"/>
2. Start Tomcat
3. Open the browser, address input: Http://localhost:8080/text (the value of the path of the Lost XML statement)/index.jsp
Tomcat environment settings and the first JSP program implementation