| 网站首页 | 业界新闻 | 小组 | 威客 | 人才 | 下载频道 | 博客 | 代码贴 | 在线编程 | 编程论坛
欢迎加入我们,一同切磋技术
用户名:   
 
密 码:  
共有 609 人关注过本帖
标题:[求助]达人看看这个jsp啊
取消只看楼主 加入收藏
gxppa2006
Rank: 1
等 级:新手上路
帖 子:178
专家分:0
注 册:2007-2-27
收藏
 问题点数:0 回复次数:1 
[求助]达人看看这个jsp啊

<%@ page language="Java"
import="Java.util.Date"
contentType="text/html;charset=gb2312"
session="true"
buffer="24"
autoFlush="false"
errorPage="ErrorPage.jsp"
isErrorPage="false"
isThreadSafe="ture"
info="page编译指令范例页面"
%>
<html>
<body>
<%
out.println("页面信息:"+getServletInfo()+"<br>");
//for(int i=0;i<=100000;i++)
//{
//out.println(i+"<br>");
//}
%>
<%
if(session.getAttribute("bk")==null)
session.serAttribute("bk","JSP");
else
session.setAttribute("bk",session.getAttribute("bk")+"book");
string inform=(String)session.getAttribute("bk");
out.println("此书为"+inform+"<br>");
Date date=new Date();
int year=1900+date.getYear();
int month=1+date.getMonth();
int day=date.getDate();
out.println("今天是"+year+"年"+month+"月"+day+"日");
%>
</body>
</html>

刚学jsp,在书上抄了这个程序,怎么不能运行啊。

HTTP Status 500 -

--------------------------------------------------------------------------------

type Exception report

message

description The server encountered an internal error () that prevented it from fulfilling this request.

exception

org.apache.jasper.JasperException: /diy/page_directive.jsp(1,1) Page directive: invalid value for buffer
org.apache.jasper.compiler.DefaultErrorHandler.jspError(DefaultErrorHandler.java:40)
org.apache.jasper.compiler.ErrorDispatcher.dispatch(ErrorDispatcher.java:407)
org.apache.jasper.compiler.ErrorDispatcher.jspError(ErrorDispatcher.java:102)
org.apache.jasper.compiler.PageInfo.setBufferValue(PageInfo.java:456)
org.apache.jasper.compiler.Validator$DirectiveVisitor.visit(Validator.java:145)
org.apache.jasper.compiler.Node$PageDirective.accept(Node.java:590)
org.apache.jasper.compiler.Node$Nodes.visit(Node.java:2336)
org.apache.jasper.compiler.Node$Visitor.visitBody(Node.java:2386)
org.apache.jasper.compiler.Node$Visitor.visit(Node.java:2392)
org.apache.jasper.compiler.Node$Root.accept(Node.java:489)
org.apache.jasper.compiler.Node$Nodes.visit(Node.java:2336)
org.apache.jasper.compiler.Validator.validate(Validator.java:1700)
org.apache.jasper.compiler.Compiler.generateJava(Compiler.java:178)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:306)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:286)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:273)
org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:566)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:308)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:320)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:266)
javax.servlet.http.HttpServlet.service(HttpServlet.java:803)


note The full stack trace of the root cause is available in the Apache Tomcat/6.0.10 logs.


--------------------------------------------------------------------------------

Apache Tomcat/6.0.10

出现上面的错误,请达人给看看哈

搜索更多相关主题的帖子: jsp false body Java 
2007-03-11 18:21
gxppa2006
Rank: 1
等 级:新手上路
帖 子:178
专家分:0
注 册:2007-2-27
收藏
得分:0 
太谢谢你了!!

临渊羡鱼,不如退而结网!
2007-03-17 18:59
快速回复:[求助]达人看看这个jsp啊
数据加载中...
 
   



关于我们 | 广告合作 | 编程中国 | 清除Cookies | TOP | 手机版

编程中国 版权所有,并保留所有权利。
Powered by Discuz, Processed in 0.045334 second(s), 8 queries.
Copyright©2004-2024, BCCN.NET, All Rights Reserved