jsp连接mysql问题请教
大哥,大姐们,小弟遇到个问题.不会解决,困扰了小弟很长时间.请教你们.谢谢啦!我用tomcat+mysql,代码
<%@ page contentType="text/html;charset=gb2312" %>
<%
java.sql.Connection conn;
java.lang.String strConn;
Class.forName("org.gjt.mm.mysql.Driver").newInstance();
conn= java.sql.DriverManager.getConnection("jdbc:mysql://localhost/mysql","root","123");
%>
可是就是连接不到mysql上面.用java可以连接到mysql上面.不知道那里有问题.报错信息:
java.lang.NoClassDefFoundError: org/aspectj/lang/Signature
java.lang.Class.forName0(Native Method)
java.lang.Class.forName(Class.java:141)
org.apache.jsp.test5_jsp._jspService(test5_jsp.java:47)
org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:94)
javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:324)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:292)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:236)
javax.servlet.http.HttpServlet.service(HttpServlet.java:802)