JSP Page Error

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 :&nbsp; <input type="text" name="fname">
Last  Name :&nbsp; <input type="text" name="lname"></br></br>
User Name  :&nbsp; <input type="text" name="uname"></br></br>
Password   :&nbsp;&nbsp;&nbsp;&nbsp <input type="password" name="pass"></br></br>
Gender     :&nbsp;<input name="Gender" type="radio" value="M">Male
<input name="gender" type="radio"  value="F">Female<br></br>
Age        :&nbsp;<input type="text" name="age"></br></br> 

State      :&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp <input type="text" name="state"></br></br>
Mobile     :&nbsp;&nbsp;&nbsp;&nbsp <input type="text" name="mno" float="left"></br></br>Address :</br></br>
&nbsp <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









Related Tutorials/Questions & Answers:
JSP error page - JSP-Servlet
JSP error page  Hi i have 1000 of JSP. but we coded it without adding the . but now i have to forward the page to the specific page when the exception occured in JSP. is there any short cut i can do? do not want to add this line
JSP Error Page
JSP Error Page          JSP Error Page is used to specify the custom error page and runtime error occurs with an exception being thrown, the custom
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;" %>
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... of the error page in the directive in the originating JSP page by setting error
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
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...; <%-- include custom error page in this jsp code --%> <%@ page errorPage
JSP error
JSP error  what is difference between global-exception and error-page in jsp. which condition they are use
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> &lt;%@ page language... encountered an internal error () that prevented it from fulfilling this request
jsp error - JSP-Servlet
jsp error  HTTP Status 404 - /jsp... message /jsp/ description The requested resource (/jsp/) is not available..., The 404 or Not Found error message is an HTTP standard response code indicating
JSP Error - JSP-Servlet
JSP Error  When i am running my registration.jsp getting following error. HTTP Status 500... description The server encountered an internal error () that prevented it from fulfilling
jsp error - JSP-Servlet
jsp error  how to remove below error:: exception org.apache.jasper.JasperException: java.lang.NullPointerException root cause...... newpo.jsp:   JSP Page
jsp error - JSP-Servlet
jsp error  Hello, my name is sreedhar. i wrote a jsp application to generate a report from oracledata base and the report should display in Ms-excel... in detail. Visit for more information. http://www.roseindia.net/jsp/ Thanks
jsp error - JSP-Servlet
jsp error  To Upload and insert the file into oracle Database with Current Date and Time In JSP and my project is online library management system plz help how to store some books in particular folder and after how retrive
Error testing in JSP
_TO_REPLACE_1 In JSP, you can specify the error page to be invoked when any error or exception is encountered. Exception and error can be handled by using two page... Error testing in JSP      
JSP Translation error - JSP-Servlet
JSP Translation error  Hello friends, In a new file declared first variable shows the following error. ----------------------------------------------- An error occurred at line: 2 in the jsp file: /stud
jsp error - JDBC
jsp error   in this code the else part is nt executing atall. if the 'id'(which i am retriving frm a html page) is nt matched with the database... of that a error is like-----------"java.sql.SQLException: [Microsoft][ODBC Driver Manager
jsp runtime error - JSP-Servlet
jsp runtime error  sir, when i am running ur prog... from this website.... http://www.roseindia.net/jsp/poi/readingWriting.shtml i did the same as per guidelines...but i got error..!!!! org.apache.jasper.JasperException
jsp code error - JSP-Servlet
jsp code error  I have a jsp page named "tMastDepartment".which has some table row containing text box like 'project code','Departmentcode','employee_id', 'address', and 'city' and a one dropdown list which contains department
Servlet Error - JSP-Servlet
/lib folder if database is mysql. servlet-api.jar jsp-api.jar mysql-connector.... Error showing ==>Admin/FirstServlet is not a servlet Sincerely Prakash   Hi prakash servlet-api.jar jsp-api.jar mysql-connector
Script error - JSP-Servlet
Script error  Hello friends, In my log in page i... running this it shows an error as "STACK OVERFLOW". Correct the code . The code... any problem then send me jsp code. Thanks
Programming Error - JSP-Servlet
Page 2 Page 3 Page 5 Page 7 Total Cost: How to use switch statement in jsp i want to calculate the price of placing ad according to user selection if he selects front page then the price given above etc please reply me how
Programming Error - JSP-Servlet
from it (only one not more than that)then it should get displayed on next page... is access). Then how to do this in jsp?? Please Reply me?? Please do Reply
jsp code error - JSP-Servlet
jsp code error  hello, is anyone here who can solve my problem. what happen experts where r u? r u not able to do
jsp code error - JSP-Servlet
jsp code error  hello, is anyone here who can solve my problem. what happen experts where r u? or u r not able to do
JScript error - JSP-Servlet
JScript error  Hello friends, I am doing jsp... logins while updating profile it will not show any error. But, in many logins it shows error as unterminated string. I am not able
Programming Error - JSP-Servlet
then the path of that should get saved in Access Database and on next page...("http://localhost:8080/examples/jsp/modify.jsp?filename="+filename
jsp-Hibernate Error - JSP-Servlet
jsp-Hibernate Error  hi, my problem is, I designed an Interface where i am tring to listing the all rows of a table using Iterator and putted a link for deleting each row. I am deleteing row using row id of that record.it delete
Programming Error - JSP-Servlet
Programming Error  How to validate login page using jsp where it checks for username whether it is empty or not or is it including number or not if it is the paste alert message.   Hi Friend, Try the following
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"/><
insertion error - JSP-Servlet
insertion error  my first jsp page : In this i m getting all the values through a method called getAllDetails,the values are getting inserted... into table. below is the codeof jsp and java pages; function
Jsp Error - Development process
Jsp Error  Hi, While executing Add_Data.jsp , am getting following error. "Data type mismatch in criteria expression." "View_Data.jsp...) at jsp_servlet.__add_data._jspService(__add_data.java:146
Programming Error - JSP-Servlet
is it possible in jsp. when user types some thing in draft ad textarea... clicks on confirm checkbox and submits then it should get displayed on next page
jsp-Hibernate Error - Hibernate
jsp-Hibernate Error  hi, my problem is, I designed an Interface where i am tring to listing the all rows of a table using Iterator and putted a link for deleting each row. I am deleteing row using row id of that record.it delete
Programming Error - JSP-Servlet
(""); } catch(SQLException se) { out.println("Database Error :"+se.getMessage()); } catch(Exception e) { out.println("General Error :"+e.getMessage... ServletException,IOException {doPost(req,res);} } There is some error
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
Jsp Error - Development process
Jsp Error  Hi, While executing following code "View_Service.jsp" , am getting Internal Server Error java.sql.SQLException: [Microsoft][ODBC...(JdbcOdbcStatement.java:288) at jsp_servlet.__add_data._jspService(__add_data.java:146
Programming Error - JSP-Servlet
there are three pages one is PlaceAd.jsp ,2nd is Preview.java and 3rd page is Payment.jsp. This code is placead.jsp and from that page I want that the value inside the count box should get transmitted to the Payment page that is through session
Programming error - JSP-Servlet
Payment Premium Position FrontPage BackPage Other Premium Pages Page 2 Page 3 Page 5 Page 7 Total Cost: I want that the no of characters... cost is Rs:170 3)frontpage:Rs:457200 4)backpage Rs:960000 5)Page 2 -Mumbai Rs
Tomcat error - JSP-Servlet
the error :-this is non microsoft product please see event log . what might be the reason of such error  HI, Can you paste the error log here.We
Programming Error - JSP-Servlet
displayed in next page where he will review his ad . I want that when user type... and that should get save in database and also should get displayed on the next page i.e preview page . and i also want that as user starts typing in draft ad
output error - JSP-Servlet
output error  /*hi friends, the given below is my servlet program error? How can i solve this problem? */ HTTP Status 500... report message description The server encountered an internal error
error message - JSP-Servlet
error message  hi, friends after complete my servlet programe i can type http://localhost:8080 on the browser. the servlet program is insert data into dbms. but i have errormessage that is "window can not access the specified
Programming Error - JSP-Servlet
that the value inside the count box should get transmitted to Payment page
Programming Error - JSP-Servlet
(); } } }//End of class m geeting error in this can u please tell me whats the error nd how to solve
Error output - JSP-Servlet
Error output  Can anyone please assist me; The printed output should be: The product is 10. But instead of it I got; The product is undefined. Can anyone trace what went wrong of my code pls
Programming Error - JSP-Servlet
integer.parseInt but its giving error. Please Reply me . Thank you
code error - JSP-Servlet
is error in this progrm. ss function describe() { window.status

Ads