JAVA连接数据库的问题MYSQL

来源:百度知道 编辑:UC知道 时间:2024/05/14 01:10:45
我下载了JDBC的驱动程序。放在TOMCAT里的common\lib里。然后在CLASSPATH里也填加了响应的JAR。可我随便写了一个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: /test.jsp(1,1) Page directive has invalid attribute: contenttype
org.apache.jasper.compiler.DefaultErrorHandler.jspError(DefaultErrorHandler.java:39)
org.apache.jasper.compiler.ErrorDispatcher.dispatch(ErrorDispatcher.java:409)
org.apache.jasper.compiler.ErrorDispatcher.jspError(ErrorDispatcher.java:200)
org.apache.jasper.compiler.JspUtil.checkAttributes(JspUtil.java:304)
org.apache.jasper.compiler.Validator$DirectiveVisitor.visit(Validator.java:100)
org.apache.jasper.compiler.Node$PageDirective.accept(Node

从出错的信息来看,你冤枉了mysql

>>org.apache.jasper.JasperException: /test.jsp(1,1) Page directive has invalid attribute: contenttype

你的test.jsp有问题。
invalid attribute: contenttype

contenttype的值不对