Hi !
After a simple call to the database using sql.jsp file in the Shopping Cart.jsp file, how do I display the message retrieved from the database on the ShoppingCart.jsp page itself instead of displaying it on a new window.
The ShoppingCart.jsp file code as under:
<tr>
<form action="/ShoppingCart/sql.jsp" method="post">
<td width="496" bordercolor="#FFFFFF"
align="center" bgcolor="#688888" height="21" width="118"><font class="listhead"><b><input type="text" name = "tex" value="Text"></font>
and sql.jsp file as under:
<%
if (rs.next()) {
out.println("<tr>\n<td>" + rs.getString("name") + "</td>");
out.println("<td align=\"center\">" + rs.getString("owner") + "</td>");
out.println("<td align=\"center\">" + rs.getString("species") + "</td>");
out.println("<td align=\"center\">" + rs.getString("sex") + "</td>");
out.println("<td align=\"center\">" + rs.getString("birth") + "</td>\n</tr>");
}
%>
</body>
</html>
When i execute the ShoppingCart.jsp file all the information from the database is picked up using the sql.jsp file and displayed on a fresh window, but how do i make it display it on ShoppingCart.jsp page itself.
Eagerly awaiting to hear.Seems like a simple doubt that i am unable to understand
Thanks
After a simple call to the database using sql.jsp file in the Shopping Cart.jsp file, how do I display the message retrieved from the database on the ShoppingCart.jsp page itself instead of displaying it on a new window.
The ShoppingCart.jsp file code as under:
<tr>
<form action="/ShoppingCart/sql.jsp" method="post">
<td width="496" bordercolor="#FFFFFF"
align="center" bgcolor="#688888" height="21" width="118"><font class="listhead"><b><input type="text" name = "tex" value="Text"></font>
and sql.jsp file as under:
<%
if (rs.next()) {
out.println("<tr>\n<td>" + rs.getString("name") + "</td>");
out.println("<td align=\"center\">" + rs.getString("owner") + "</td>");
out.println("<td align=\"center\">" + rs.getString("species") + "</td>");
out.println("<td align=\"center\">" + rs.getString("sex") + "</td>");
out.println("<td align=\"center\">" + rs.getString("birth") + "</td>\n</tr>");
}
%>
</body>
</html>
When i execute the ShoppingCart.jsp file all the information from the database is picked up using the sql.jsp file and displayed on a fresh window, but how do i make it display it on ShoppingCart.jsp page itself.
Eagerly awaiting to hear.Seems like a simple doubt that i am unable to understand
Thanks