JSP Page Error
Hello Sir.
I m using Oracle 10g as a database n tomcat server
DSN name : NB
Username NB
Password EBS
Table name consumer
When i run jsp page on the browser it only shows the code nothing else..
I have made two files which are as follows
1)New.jsp
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<title>Net Bill</title>
<link rel="stylesheet" type="text/css" href="C:\NB\stylesheets\main.css"></link>
<!--[if IE]>
<script src="http://html5shim.googlecode.com/svn/trunk/html5.js"></script>
<![endif]-->
</head>
<body>
<div class="header">
<center><p style="padding-top:30px; font-size:40px; color:#000040;">Net Bill</p></center>
</div>
<div class="nav">
<ul style="list-style-type:none; margin:0px; padding:0px; overflow:hidden;">
<li style="float:left"><a href="C:\NB\Index.html">Home</a></li>
<li style="float:left"><a href="C:\NB\About.html">About Us</a></li>
<li style="float:left"><a href="C:\NB\How.html">How it Works</a></li>
<li style="float:left"><a href="C:\NB\Contact.html">Contact Us</a></li>
</ul>
</div>
<!-- Start of FORM -->
<form method="post" action="insert.jsp.">
<table style="width:700px; height:200px; margin:10px 80px; padding-top:10px; padding-left:30px; font-size:20px; border-radius:6px; background-color:#000000; color:#C0C0C0;">
<tr>
<td>
First Name : <input type="text" name="fname">
Last Name : <input type="text" name="lname"></br></br>
User Name : <input type="text" name="uname"></br></br>
Password :   <input type="password" name="pass"></br></br>
Gender : <input name="Gender" type="radio" value="M">Male
<input name="gender" type="radio" value="F">Female<br></br>
Age : <input type="text" name="age"></br></br>
State :   <input type="text" name="state"></br></br>
Mobile :   <input type="text" name="mno" float="left"></br></br>Address :</br></br>
  <textarea style="width:200px; height:50px;"name="address"></textarea></br></br></br>
<center><button type="Submit" name="send" width="100px" height="10px">Submit</button></td></center>
</tr>
</table>
</form>
<!-- End of FORM -->
<div class="footer">
<center><strong>Copy Rights @ Arth Parikh</strong></div></center>
</body>
</html>
2) insert.jsp
<%@ page import="package oracle.jdbc.driver;" %>
<%@ page language ="java" %>
<%@ page import="java.sql.*" %>
<%@ page import="java.io.*" %>
<%@ page import="java.util.*" %>
<%
String fname = request.getParameter("fname");
String lname = request.getParameter("lname");
String uname = request.getParameter("uname");
String pass = request.getParameter("pass");
String gender = request.getParameter("gender");
String age = request.getParameter("age");
String state = request.getParameter("state");
String address = request.getParameter("address");
String mno = request.getParameter("mno");
int mno=Integer.parseInt(request.getParameter("mno"));
try{
Class.forName("oracle.jdbc.OracleDriver");
Connection conn = DriverManager.getConnection("jdbc:oracle:thin:@localhost:1521:xe","NB","EBS")
Statement st=conn.createStatement();
Resultset rs=st.executeUpdate("insert into consumer(fname,lname,uname,pass,gender,age,state,address,mno) values('"+fname+"','"+lname+"','"+uname+"','"+pass+"',"+age+",'"+gender+"','"+address+"','"+state+"',"+mno+")");
out.println("Data is successfully inserted!")
}
catch(Exception e)
{
System.out.print(e);
e.printStackTrace();
}
%>
Sir please help me as soon as possible my project is on stand by...so soon want a perfect solution.
View Answers
Ads
Related Tutorials/Questions & Answers:
JSP Error Page
JSP Error Page
JSP Error Page is used to specify the custom... directive. The
page errorPage.jsp shows the
error generated in calling
the
JSP page
JSP Page Error
JSP Page Error Hello Sir.
I m using Oracle 10g as a database n... i run
jsp page on the browser it only shows the code nothing else..
I have...;/html>
2) insert.jsp
<%@
page import="package oracle.jdbc.driver;" %>
Advertisements
JSP Page Error
JSP Page Error Hello Sir.
I m using Oracle 10g as a database n... i run
jsp page on the browser it only shows the code nothing else..
I have...;/html>
2) insert.jsp
<%@
page import="package oracle.jdbc.driver;" %>
JSP Page Error
JSP Page Error Hello Sir.
I m using Oracle 10g as a database n... i run
jsp page on the browser it only shows the code nothing else..
I have...;/html>
2) insert.jsp
<%@
page import="package oracle.jdbc.driver;" %>
Error page in JSP
Error page in
JSP
In this section we will discuss about "
Error page... the
JSP page a runtime
error may occur
inside the
page or outside the
page.
JSP... in the directive in the originating
JSP
page by setting
error page parameter like
error while running a jsp page in netbeans
error while running a
jsp page in netbeans this is
error that come under column "java db processes" in netbeans
Exception in thread "main" java.lang.ExceptionInInitializerError
JSP error
JSP error what is difference between global-exception and
error-
page in
jsp. which condition they are use
How to create and use custom error page in jsp
How to create and use custom
error page in
jsp... and use custom
error page in
jsp and display an
error message.
Before run.../TR/html4/loose.dtd">
<%-- include custom
error page in this
jsp
jsp error
jsp error <p>hi, could please help whenever i run
jsp file in my eclipse i got this error.my
jsp file is</p>
<%@
page language... encountered an internal
error () that prevented it from fulfilling this request
Error testing in JSP
" %>.
The
JSP page where the exception can occur specifies the
error page name...
Error testing in
JSP
This section illustrates you about the
error testing in
jsp.
In
JSP, you
JSP SQL Error
JSP SQL Error Hi While trying to execute the below code i'm getting the following
error "java.sql.SQLException: Io exception: Got minus one from a read call ". please help me out.
<%
try{
String Username
jsp-servelet,error http404
jsp-servelet,
error http404 I am using mysql commandclient to connect with eclipse using
jsp and servelet.
I keep getting the
error hhtp 404.
Register.jsp
Name:<input type="text" name="userName"/><
JSP Error 500
JSP Error 500
JSP Error 500 is to generate
error status 500 in
jsp. The
Error 500
occurred when the server encounter an internal
error
Dynamin Jfree chart in jsp---error
error details.
Have a look at the following link:
http://www.roseindia.net/
jsp...Dynamin Jfree chart in
jsp---error While compiling this CODE:
<%@
page import="java.sql.*" %>
<%@
page import="java.io.*" %>
Jsp error when i run this a jsp file
Jsp error when i run this a
jsp file hi
I got this
error when i run the
jsp file in IDE and outside also
please help me
java.lang.NullPointerException
org.apache.jsp.insertjsp.jspInit(insert_jsp.java:22
Showing Error for Prepared stmt in a jsp
Showing
Error for Prepared stmt in a jsp i hav a task to connect
jsp...
org.apache.jasper.JasperException: Unable to compile class for
JSP:
An
error occurred...=pstmt.executeUpdate();
31: %>
An
error occurred at line: 29 in the
jsp file
Showing Error for Prepared stmt in a jsp
Showing
Error for Prepared stmt in a jsp i hav a task to connect
jsp...
org.apache.jasper.JasperException: Unable to compile class for
JSP:
An
error occurred...=pstmt.executeUpdate();
31: %>
An
error occurred at line: 29 in the
jsp file
jsp page
jsp page <%@
page contentType="text/html" pageEncoding="UTF-8"%>...;%@
page import="java.sql.Statement"%>
<%@
page import="java.sql.DriverManager"%>
<%@
page import="java.sql.Connection"%>
<%@
page import
jsp page
jsp 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">
login page error
login
page error How to configure in to config.xml .iam takin... following
error arise ."The server encountered an internal
error (No action instance... this request."
please suggest me.
if your login
page is prepared
Spring Login Page Error
Spring Login
Page Error Dear Sir/Madam,
I used the spring login
page code. The index
page is working fine. When i try to entry login and password , i am getting the below
error: Please help me out in this. Let me know if i
The Page Directive in JSP Page
; in
JSP page. And then if a type of
error occurs i.e. called the translation-time...
The
Page Directive in
JSP Page
 ... of the
JSP page which works for the entire
JSP page. These directives
apply different
Easily create JSP page
Easily create
JSP page Hi,
How I can easily create
JSP page? Where to run the
JSP page easily?
Thanks
Hi,
JSP stands for Java Server Pages and its easy to create a simple
JSP page.
Check the tutorial: How
jsp page submitting
jsp page submitting whenever i am submitting the
jsp page it downloads some unknown file on tomcat server
JSP Hindi Page - JSP-Servlet
JSP Hindi Page I need to provide users with option to print a Certificate in English or Hindi. This is an html
page generated by
JSP Code. Depending upon the button clicked english or hindi version of the Certificate should
Unable to execute JSP page
folder.
But I could not execute the
JSP page. Please help me...Unable to execute
JSP page I have written one
jsp file. It contains html tags and
jsp directives. I have saved the file with the extension .
jsp
Search Page in jsp
Search
Page in jsp search
page in
jsp
Please go through the following links:
http://www.roseindia.net/
jsp/user-search.shtml
http://www.roseindia.net/servlets/search.shtml