Bobo,
the line numbers actually refer to the generated Java code, which is in a
repository directory as defined by your cocoon.properties file. I think
your first error here is missing semicolons on the lines
String fname = request.getParameter("fname")
...//some more request.getParameter()
String email = request.getParameter("email")
-Christopher
Please respond to [EMAIL PROTECTED]
To: <[EMAIL PROTECTED]>, <[EMAIL PROTECTED]>
cc:
Subject: XSP: Type and Identifier errors
Hello,
I am receiving this error:
java.lang.Exception: XSP Java Compiler: Compilation failed for
_newUser.java
72: Type expected.
Class.forName("org.gjt.mm.mysql.Driver").newInstance();
^
240: Identifier expected.
xspParentNode = xspCurrentNode;
----- ^
The ligne 72: points to isIDduplicate()
function while the line 240 points to if-else.
I am using cocoon 1.8.2 and Tomcat3.2.1
Here is my code (this program is for form handling):
<?xml version="1.0"?>
<?cocoon-process type="xsp"?>
<?cocoon-process type="xslt"?>
<?xml-stylesheet href="../../userFactory.xsl" type="text/xsl"?>
<xsp:page language="java" xmlns:xsp="http://www.apache.org/1999/XSP/Core">
<xsp:structure>
<xsp:include> java.lang.*</xsp:include>
<xsp:include> java.sql.*</xsp:include>
<xsp:include>java.sql.Date</xsp:include>
<xsp:include> java.sql.DriverManager</xsp:include>
<xsp:include> java.sql.SQLException</xsp:include>
<xsp:include>java.sql.Connection</xsp:include>
<xsp:include>java.sql.ResultSet</xsp:include>
<xsp:include>java.sql.Statement</xsp:include>
</xsp:structure>
<xsp:logic>
String fname = request.getParameter("fname")
...//some more request.getParameter()
String email = request.getParameter("email")
Class.forName("org.gjt.mm.mysql.Driver").newInstance();
String serverName =request.getServerName();
String
URL="jdbc:mysql://"+serverName+"/ILSDB?user=Bobo&password=BoboPassword";
Connection con = DriverManager.getConnection(URL, "", "" );
Statement stmt1=
con.createStatement(ResultSet.TYPE_SCROLL_SENSITIVE,ResultSet.CONCUR_UPDATAB
LE);
Statement stmt2=
con.createStatement(ResultSet.TYPE_SCROLL_SENSITIVE,ResultSet.CONCUR_UPDATAB
LE);
<snip>
---------------------
I need your help.
Thank you.
Bobo,
---------------------------------------------------------------------
Please check that your question has not already been answered in the
FAQ before posting. <http://xml.apache.org/cocoon/faqs.html>
To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>