/**
* Servlet implementation class GuestBookServlet
*/
public class GuestBookServlet extends HttpServlet {
private static final long serialVersionUID = 1L;
/**
* @see HttpServlet#HttpServlet()
*/
public GuestBookServlet() {
super();
// TODO Auto-generated constructor stub
}
} catch (Exception e) {
e.printStackTrace();
}
if (name== null || email== null || comments == null){
out.println("The guestbook cannot be signed if you have left any of the fields blank");
}
out.println("you are the guest No: "+ rowCount);
}
}
MyJSP Page
<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
pageEncoding="ISO-8859-1"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<body>
<table>
<tr>
<jsp:useBean id="list" class="java.util.ArrayList" scope="session"/>
<jsp:useBean id="it" class="java.util.Iterator" scope="session"/>
<%String book=request.getParameter("all");%>
</tr>
</table>
Please be sure to use code tags when posting code to the forums. Unformatted code is extremely hard to read and many people that might be able to help you will just move along to posts that are easier to read. Please read this for more information.
You can go back and change your post to add code tags by clicking the button on your post.
Sakthi Ramasamy wrote:I donot know how to post it in the same page.
Check for a boolean flag or something (which is set after checking whether user has valid entries in DB) then display the data where you want them in the JSP.
The reason for duplicate post is the thought that my post might not get noticed. but i clicked the resolved option as i didn't know how to delete the post.
I am [b]extremely sorry[/b] for the people, whose time i have wasted and caused some irritation.
[u]I thank you very much for the ideas that you have provided for me to solve the issue[/u].
I assure that the next time i post some issues, i will follow the rules.
Best Regards,
Sakthi.
Post by:autobot
bacon. tiny ad:
a bit of art, as a gift, that will fit in a stocking