js| Error | Page <title>my the Guestbook</title>
<meta http-equiv= "Content-type" content= "text/html; charset=gb2312 ">
<body bgcolor= "#ccccFF" vlink= "#000000" alink= "#666666" >
<div align= "center" >
<p><font size= "7" ><b><font size= "+6" >jsp aguestbook</font></b></font> </p>
<form method= "POST" action= "index1.jsp" >
<table width= "75%" align= "center" border=1>
<tr>
<TD width= "30%" >
<div align= "right" name:</div>
</td>
<TD width= ">"
<input type= "text" name= "name" >00000
</td>
</tr>
<tr>
<TD width= "30%" >
<div align= "right" > e-mail:</div>
</td>
<TD width= "70%" >
<input type= "text" name= "email" >
</td>
</tr>
<tr>
<TD width= "30%" >
<div align= "right" >site >
</td>
<TD width= "70%" >
<input type= "text" name= "url" value= "http://" >
</td>
</tr>
<tr>
<TD width= "30%" >
<p>what Do you want to</p>
<p>say?</p>
</td>
<TD width= "70%" >
<textarea name= "Body" rows= "5" cols= "></textarea>"
</td>
</tr>
<tr>
<td> </td>
<td> </td>
</tr>
<tr>
<TD width= "70%" > </td>
<TD width= "70%" >
<table width= "75%" >
<tr>
<td>
<input type= "Submit" name= "send" value= "send" >
</td>
<td>
<input type= "reset" name= "reset" value= "reset" >
</td>
</tr>
</table>
</td>
</tr>
</table></form>
<%@ page contenttype= "text/html;charset=gb2312"%>
<%@ page language= "java" import= "java.sq1.*"%>
<jsp:usebean id= "Sq1bean" scope= "page" class= "jsp.mysq1"/>
<%! String name,email,url,body,sq1; %>
<%! int id; %>
<%
name = NULL;
Name = Request.getparameter ("name");
%>
<%
if (name!= null&&name!= "")
{
name = new String (Request.getparamer ("name"). GetBytes ("8859_1"));
email = new Steing Request.getparamer ("email"). GetBytes ("8859_1");
url = new String (request.getparamer ("url"). GetBytes ("8859_1"));
Body=newsteing (Request.getparamer ("Body"). GetBytes ("8859_1"); sq1= "Insertintoguestbook" (name,email,url,body)
VALUES (' +name+ ', ' "+email+ ', '", ' "=url+ ', '" +body+ ")";
Sq1bean.executery (SQ1);
Sq1bean.sq1close ();
}else{
Out.print ("<b><font color=red>please Enter your name,email and body!!! </font>
</b> ");
}
%>
<p><font size= "4" ><b><a href= "./index.jsp#see" >see my guestbook</a></b>
</font></p>
<p> </p>
<%
ResultSet RS = Sq1bean.executequery ("SELECT * FRM Guestbook ORDER BY RecordID
DESC ");
while (Rs.next ()) {
Name =new String (rs.getstring ("Name"). GetBytes ("8859_1"));
Email =new String (rs.getstring ("Email"). GetBytes ("8859_1"));
Uel =new String (rs.getstring ("Ual"). GetBytes ("8859_1"));
Body =new String (rs.getstring ("Body"). GetBytes ("8859_1"));
%>
<table border=1>
<tr>
<td>name:</td><td><%= Name%>
</td>
</tr>
<tr>
<td>email:</td><td><a href= "mailto:<%= email%>" ><%= Email%></a></td >
</tr>
<tr>
<td>siteurl;</td><td><a href= "<%= url%>" ><%= url%></a></td>
</tr>
<tr>
<td>body:</td><td><%= Body%></td>
</tr>
</table>
<%
}
Rs.close ();
Sq1bean.sq1close ();
%>
</div>
</body>