Need help in creating a webpage application as follows:
home.jsp which calls
*navigation.jsp
*contact.jsp
navigation.jsp displays as a header on each page
*The current date and time
*The company logo
Links displaying
*Home
*Products
*Order
Printable View
Need help in creating a webpage application as follows:
home.jsp which calls
*navigation.jsp
*contact.jsp
navigation.jsp displays as a header on each page
*The current date and time
*The company logo
Links displaying
*Home
*Products
*Order
Are you looking for a programmer or what?
What have you done so far?
i need an html code.
i have written this so far..
<%@ page language = "java" %>
<html>
<head>
<title>My first JSP Home page
</title>
</head>
<body>
<%@ page language="java" %>
<% out.println("Home page"); %>
</body>
</html>
thats what i have to do for my project..
Create a webpage application as follows:
home.jsp which call
navigation.jsp
contact.jsp
navigation.jsp displays as a header on each page
The current date and time
The company logo
Links displaying
Home
Products
Order
contact.jsp displays as a footer on each page
counter e.g. You are customer number: xxx
Organisation’s web address
Email address for enquiries
Write a general introduction – a few lines – on the company in home.jsp and display a few images of the products in products.jsp.
order.jsp should allow the user to enter their:
name
address (as a textArea box or several input boxes)
password
password confirmation
The user can also:
Select a product from a drop down menu.
Enter a quantity in an input box.
Select their preferred method of payment from a set of radio buttons e.g. VISA, Mastercard, etc.
Select their preferred time of delivery (a.m. or p.m.) from radio buttons.
Tick 2 checkboxes to choose a free gift from 4/5 items listed.
Complete a textArea box called, Special Delivery Instructions.
order.jsp contains a Submit and a Reset button.
order.jsp should call display.jsp.
display.jsp should display the user’s order details and have a return button which calls allows the user to return to order.jsp to change their order and a link which the user presses to comfirm their order. If the user presses the link to confirm their order, confirm.jsp is displayed
confirm.jsp should thank the user, by name, for placing their order. You may need to use sessions in order to display the user’s name on this page.
display.jsp also checks for BLANK entries (name and address only) and incorrect PASSWORD confirmation. If any of these entries are invalid, you should forward the user to another page called invalid.jsp and inform the user of the incorrect entries and ask them to return to order.jsp to re-enter their order correctly again. This check for invalid entries should be done at the start of display.jsp. (Hint: Use Java statement .equals(“ ‘)).
Every jsp page that you generate should call:
navigate.jsp and contact.jsp
an error page for detailing any runtime errors
Your web pages must all be formatted neatly, preferably using tables.
Your website can be based on any product you like e.g. books, flowers, home heating oil, computer products, dvds, videos,
Please choose the correct sub-forum when you ask a question again. This sub-forum for XML related questions. But the your one is much related to JSP.
I'll move this thread to the correct place this time. Please pay your attention on that next time. :)
Hi Eranga,
Just like to ask you that where did u move my thread..I checked under jsp title..but it is not there.
Let me know soon plz.
Thanks
Do you know how to work with HttpRequests and HttpResponse ?Any knowledge about Servlets?
i say i know a bit of it..sorry i m just new to that.
for my code..i have just written this..
<%@ page language = "java" %>
<html>
<head>
<title>My first JSP Home page
</title>
</head>
<body>
<%@ page language="java" %>
<% out.println("Home page"); %>
</body>
</html>
JSP FUNDAMENTALS
This a pretty good site for learning JSP,learn and in a week you will know what is going on.
If you want to create components,you should create them from html code in the form tags,and to declare what is going on when you submit the form,if you use Servlets,so it will execute the servlet,then don't forget to point wich action is that-get or post.Each component should have its name so that you can then to know what was chosen or written in the component as a request parameter .
thanks for that.
I just registered to java forums yesterday..so new to that as well..can u plzz tell me from where i can learn about jsp..I knw there is too much stuff about that on internet.
And for now can u tell me how can I start this project..as I only have few days to give that..so really need help in this..
Thanks in advance
You will not get this project built in a few days with skills displayed, go ahead and ask for you old job back flipping burgers.
i know but can u plzz give me some sort of code or link from where i can learn and start this..
Ok,man create in Eclipse Dynmic Web Project,then create index.jsp file in Web-content folder:
Then create a servlet with name LoginServlet:Code:<html>
<head>
<title>New Page 1</title>
</head>
<body>
<h2>Login</h2>
<p>Please enter your username and password</p>
<form method="GET" action="LoginServlet">
<p> Username <input type="text" name="username" size="20"></p>
<p> Password <input type="text" name="password" size="20"></p>
<p><input type="submit" value="Submit" name="B1"></p>
</form>
<p> </p>
</body>
</html>
Open the web.xml file in Web-Content and check if it has the following lines:Code:import java.io.*;
import javax.servlet.*;
import javax.servlet.http.*;
public class LoginServlet extends HttpServlet{
public void doGet(HttpServletRequest request, HttpServletResponse response)
throws ServletException, IOException {
response.setContentType("text/html");
PrintWriter out = response.getWriter();
String name = request.getParameter("username");
String pass = request.getParameter("password");
out.println("<html>");
out.println("<body>");
out.println("Thanks Mr." + " " + name + " " + "for visiting roseindia<br>" );
out.println("Now you can see your password : " + " " + pass + "<br>");
out.println("</body></html>");
Then run it on server,but before configure the server in eclipse.Code:
<?xml version="1.0" encoding="ISO-8859-1"?>
<!--<!DOCTYPE web-app
PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN"
"http://java.sun.com/dtd/web-app_2_3.dtd"> -->
<web-app>
<servlet>
<servlet-name>Hello</servlet-name>
<servlet-class>LoginServlet</servlet-class>
</servlet>
<servlet-mapping>
<servlet-name>Hello</servlet-name>
<url-pattern>/LoginServlet</url-pattern>
</servlet-mapping>
</web-app>
So as you see the our parameters are username and password and they are the names of the fields in html file.The input fields are between the form tags,the form gets the action for calling LoginServlet servlet and the "GET" method will be executed
HI
Enjoy the java community......................................
Welcome to our community. :)
We have a separate sub-forum for introduction. Actually we have well organized set of sub-forums for different Java technologies. You must select the best next time, to ask your questions. Please read our FAQ page. For this time I'll move this thread into the correct sub-forum.