This article mainly introduces how to use sysdeo eclipse Tomcat launcher plugin to edit and debug JSP and Servlet. It is best to first refer to my previous article "Illustration using eclipse3.0.1 + lomboz3.0.1 + tomcat5.0.28 to develop jsp" series, it can deepen understanding of the article.
I. Required Software
Sysdeo eclipse Tomcat launcher plugin Home http://www.sysdeo.com/eclipse/tomcatPlugin.html download http://www.sysdeo.com/eclipse/tomcatPluginV3.zip this is an Eclipse plug-in that can help edit JSP files. Install the plug-in. For more information, see install the Eclipse plug-in using links.
II. Environment ConfigurationTo edit and debug JSP files, Environment configuration is troublesome. Pay attention to the following points. 1. Check the environment variable settings. Right-click "my computer"-> advanced-> environment variable, and check whether the java_home and atat_home variables point to the installed directory. Whether the PATH variable contains "% java_home %/bin; "; whether the classpath variable contains" % java_home %/lib/tools. jar; "2. point the Java Runtime Environment in eclipse to JDK instead of JRE. In the main window of ipve, choose Window> preference> JAVA> installed JRE 3. Configure the sysdeo Tomcat plug-in.
Context description |
The context element represents a web application and runs on a specific VM. Each web application is based on a web application archive (WAR) file or a directory that contains the decompressed content of the war file. By matching the longest possible prefix of the request URI with the context path of each context, Catalina selects the corresponding web application to process HTTP requests. Once selected, according to the servlet ing defined in the Web application deployment descriptor file, context selects a correct servlet to process incoming requests. Servlet mappings must be defined in/WEB-INF/Web. XML in the Web application directory hierarchy. You can nest any number of context elements in a host element. The path of each context must be unique and defined by the path attribute. In addition, you must define a context whose path length is 0. This context is called the default web application of the VM and is used to process requests that cannot match any context path. In addition to nesting the context element in the host element, you can also store them in a single file. put XML in the $ catalina_home/CONF/[enginename]/[hostname]/directory. (Note: Catalina is the alias of Tomcat) |
Switch to the advanced option to switch to the JVM setting option to the Tomcat manger app, and add a user to the management interface. Click "application" and "OK. 4. Add "Tomcat project" to the "new" menu. Window> Custom perspective> shortcut> New> JAVA
Use eclipse3 + sysdeo Tomcat plugin to edit and debug JSP (2)
Use eclipse3 + sysdeo Tomcat plugin to edit and debug JSP (3)