Graphical use Eclipse3 + Sysdeo Tomcat Plugin editing and debugging JSP (2)

xiaoxiao2021-03-06  87

Graphical use Eclipse3 Sysdeo Tomcat Plugin editing and debugging JSP (1) III. Writing

1. Create a Tomcat project.

Right-click on the "Pack Explorer" window, new creation -> Tomcat Project

Fill in the project name: TomcatSample, click "Finish".

2. Right-click "Tomcatsample", new-> file, fill in the file name: Index.jsp

3. Modify Index.jsp

Tomcatsample / index.jsp.jsp

<%

String s = "Welcome JavaMxj Blog!";

Out.println (s);

%>

4. Click "Run Tomcat" icon

5. If everything is normal, enter "http: // localhost: 8080 / tomcatsample / index.jsp" in the browser window.

IV. Debug JSP program

1. Right-click the Work directory under the Tomcatsample project, click "Refresh" in the pop-up menu. After clicking, you will find that there is a file in this directory, open the "index_jsp.java" file, in the right column "Out.println (s);" add a breakpoint.

2. Then refresh the browser window. At this point, Eclipse will pop up a window, ask if you switch to the "Debug" view, select "Yes".

3. In this view, find the variable S, right click, select "Changed value", enter "Sysdeo Tomcat Plugin!" In the pop-up window.

4. Click the "Continue" button.

5. At this time, the browser window has reflected the debugging changes.

Graphical use Eclipse3 Sysdeo Tomcat Plugin editing and debugging JSP (3)

转载请注明原文地址:https://www.9cbs.com/read-104806.html

New Post(0)