在eclipse当中如何做一个jsp的helloWorld?

1.jsp的helloWorld:

做jsp的实验步骤非常简单。在eclipse当中,右键点击代表你WebModule的根目录的WebContent。new/jsp 即可。

例 1.1


<%@ page contentType="text/html; charset=GBK"%>
<html>
<%!private int accessCount = 0;%>
<%!double called() {
        return Math.random();
    }%>
<%=++accessCount%>
<%
    if (called() < 0.5) {
%>
天气好
<%

详情请见:http://www.mark-to-win.com/index.html?content=Jsp/jspUrl.html&chapter=Jsp/jsp3_web.html#jsphelloWorld

猜你喜欢

转载自blog.csdn.net/mark_to_win/article/details/84797891