Design an html page for buyonline

Assignment Help PHP Web Programming
Reference no: EM132510946

COS80021 Web Application Development - Swinburne University

Assignment - Web Application Development

Assignment Tasks

The assignment is to develop a simplified web-based online shopping system called BuyOnline. A site map and four components (registration and login/buying for customers, login/listing and processing for store managers) of BuyOnline that must be completed for this assignment are specified in the sub-sections below. You may explore further functions such as detailed payment processing, delivery and password changing for fun later. For this assignment, you must use XMLHttpRequest for client/server communications.

Task 1: Site Map

Design an HTML page for BuyOnline (buyonline.htm) with links for Customer Registration (see register.htm in Task 2), Customer Login (see login.htm in Task 4.1), and Store Manager Login (see mlogin.htm in Task 3.1).
After a customer successfully log into the system, the system will re-direct to the customer buying page (see buying.htm in Task 4.2). After a store manager successfully log into the system, links will appear allowing the manager either list items (see listing.htm in Task 3.3) or process the sold items (see processing.htm in Task 5.1). After a new customer finishes registration, a "back" link allows the customer return to BuyOnline page (see Task 2.4). After a customer finishes buying or a manager finishes listing or processing, a "logout" link allows the customer or manager leave the system, and a "thanks" message, which includes the customer id or the manager id, will be displayed (see Task 4.7, Task 3.5 and Task 5.3, respectively).

Task 2: Customer Registration

This component is used to allow a new customer to register into the system. The system maintains an XML document to record customer information. The specific functions of this component include
1) Design and create an XML document (customer.xml) for storing information of all customers. For each customer, you need to keep the system generated customer id, first name, surname, unique email address, password and contact phone number.
2) Design an HTML page (register.htm) for new customer registration. The inputs include email address, first name, last name, password, re-typed password (for double checking) and optional contact phone number.
3) Create client and server-side programs to get and validate inputs. Either the client- side or the server-side program will check (a) all inputs except the contact phone number are given, (b) the password is the same as the re-typed one, (c) the optional contact phone number shall follow either (0d)dddddddd or 0d dddddddd, and (d) the email address is unique (i.e., it has not been used by other customers in customer.xml). If not, the corresponding error message will be displayed.
If there is no problem with the above checking, the server-side program will generate a customer id and store all the required information for the customer into the XML document. If the XML document does not exist (i.e. when the first customer is registered in the system), create a new one. Finally, the client-side program will show the successful registration information.
4) A "back" link will be created to bring the system back to BuyOnline page
buyonline.htm.

Task 3: Manager Login and Listing

This component is used to allow a store manager to add an item into BuyOnline. The inputs for the item include item name, unit price, quantity available, and description. Once you get these inputs, you need to validate the inputs and add the details of the item in an XML document on the server side, and generate an item number for the item. The specific functions of this component include
1) Design an HTML page (mlogin.htm) to allow a manager to log into BuyOnline. A manager needs to provide a manager id and a password to get into the system. We assume that a file called manager.txt exists (with multiple lines: John, JOH121280\n Jane, JAN020578\n Anna, ANN151085\n ... ...) and you need to place it together with other XML documents in the /data folder. Each line records the manager id and the password. The inputted manager id and password are checked against the file. If the manager's information exists in the file, the manager id will be remembered by the system and two links for listing (see listing.htm in Task 3.3) and processing (see processing.htm in Task 5.1) will appear; otherwise, login failure message will be displayed for invalid manager id or password. You may choose to use a session variable to keep the manager id. If the listing link or the processing link is pressed, re-direct to listing.htm or processing.htm.

2) Design an XML document (goods.xml) for storing all items added. The XML document may store more information for the item than those inputted, including the item number generated, quantity on hold (reserved but with payment not yet confirmed), and quantity sold.
3) Design an HTML page (listing.htm) to add an item (see Figure 1).
4) Create client and server-side programs to get inputs and validate the inputs. If the data validation has problem, show an error message. Otherwise, the server-side program will generate the item number, and add it with the inputs to the XML document. The initial values for quantity on hold and quantity sold are set to 0. If the XML document does not exist (i.e. when the first item is entered in the system), create a new one. Finally, the client-side program needs to display under the inputted data "The item has been listed in the system, and the item number is:
<itemNumber>".
5) As stated in Task 1, if the "logout" link is pressed, a logout page logout.htm will display a "thanks" message, which includes the manager id.

Task 4: Customer Login and Buying
This component allows an existing customer to login, view all available items and put interested items in a shopping cart for purchasing. The specific functions of this component include
1) Design an HTML page (login.htm) to allow an existing customer to log into BuyOnline. The email address and password are required and they are checked against the XML document customer.xml. If a customer is matched against the information stored in the XML document, the customer id of this customer will be remembered by the system and the page for buying (buying.htm) will show up;

otherwise, login failure message will be displayed for invalid email address or password. You may choose to use a session variable to keep the customer id.
2) Design an HTML page (buying.htm) with AJAX techniques to periodically (say, every 10 seconds) retrieve data from the XML documents and neatly display all available items in a table as a catalog. An item is available if the quantity available is greater than 0. For each item, display in a row the item number, name, first 20 characters of the description, price, and quantity available (See Figure 2). Don't display the quantity on hold, and quantity sold.
3) For each displayed item, add a button "add one to the cart" at the end of the row. Once this button is pressed, the XML document is checked to see if the item is available (i.e., quantity available is greater than 0). If not, alert "Sorry, this item is not available for sale"; otherwise, first update the XML document by subtracting 1 from the quantity available and adding 1 to the quantity on hold, then update the shopping cart (see (4)).
4) Under the catalog, display a shopping cart (Also see Figure 2). When the button "add one to the cart" is pressed on an available item in (3), if the item is not in the shopping cart, a new row is created and the item number, quantity with value 1, and the price are displayed; otherwise the quantity for the item is increased by 1.
5) At the end of each row in the shopping cart, a button "remove from the cart" is displayed. If this button is pressed, delete the row from the shopping cart, and update the XML document for the item by decreasing the quantity on hold and increasing the quantity available by the quantity shown in the shopping cart.
6) Under the shopping cart, add two buttons "confirm purchase" and "cancel purchase". If the button "confirm purchase" is pressed, for each item in the shopping cart, update the XML document by decreasing the quantity on hold and increasing the quantity sold by the quantity shown in the shopping cart; then calculate the total amount due to pay, clear the shopping cart, and display the message "Your purchase has been confirmed and total amount due to pay is
tiny_mce_markerlt;totalAmountDue>". If the button "cancel purchase" is pressed, for each item in the shopping cart, update the XML document by decreasing the quantity on hold and increasing the quantity available by the quantity shown in the shopping cart, clear the shopping cart, and alert "Your purchase request has been cancelled, welcome to shop next time".
7) When the "logout" link is pressed, if the shopping cart holds any item, cancel the purchase first. After that, a logout page logout.htm will display a "thanks" message, which includes the customer id.

Task 5: Manager Processing

This component allows store managers to process sold items from time to time.
1) Design an HTML page (processing.htm) that displays in a table all those items with non-zero sold quantities from the XML document goods.xml. The item number, name, price, quantity available, quantity on hold, and quantity sold will be displayed. Add a "process" button under the table (See Figure 3).

2) When the button "process" is pressed, you are required to update the XML document by clearing the quantity sold for all those items with sold quantities, and removing those items that have been completely sold, i.e., both quantity available and quantity on hold equal to 0. (Note: in real application, you need to calculate the revenue generated out of the sold items. For this assignment, you are not required to do this calculation.)
3) As stated in Task 1, if the "logout" link is pressed, a logout page logout.htm will display a "thanks" message, which includes the manager id.

Attachment:- Web Application Development.rar

Reference no: EM132510946

Questions Cloud

Determining the horesis instrument : Explain why it is necessary to include only one chain-terminating/synthesis-terminating nucleotide in each well of the electrophoresis instrument
ENGT5114 Sustainable Energy Assignment : ENGT5114 Sustainable Energy Assignment Help and Solution - De Montfort University, UK - Assessment Writing Service - Sustainable Energy for an Island
America historical greatness and uniqueness : The Constitution lies at the heart of both America's historical greatness and its uniqueness. What are the main principles in the US Constitution?
Design and development may be in canada : What obstacles you might encounter in each phase from design to delivery; and What legal solutions you will employ to overcome these obstacles.
Design an html page for buyonline : Web Application Development - Design an HTML page for BuyOnline (buyonline.htm) with links for Customer Registration and Store Manager Login
How information used in decision making process new facility : How can this information be used in the decision making process for the new facilities? Does it cause any confusion? Which is the best proposal in your overview
Paula plaintiff really bad week : What types of legal claims could Paula make against Cash Mart and Geoffrey? What are the possible tort claims that Paula can make against Cash Mart?
Find where will fixed overhead incurred during the year : For a company using variable costing, where will fixed overhead incurred during the year be reported in the financial statements at the end of the period?
Harding v commissioner of taxation : During your meeting with Harry, he advised that he is considering working outside of Australia for an extended period.

Reviews

Write a Review

PHP Web Programming Questions & Answers

  Random integral numbers based on normal distribution

Prepare a system to generate random integral numbers based on normal distribution. Study Data Generator's structure and extend number generation type to activate normal distribution.

  Shopping cart program for web applications class

Shopping Cart program for web applications class. Allows user to browse while keeping track of the items in which they will purchase at the end on the order page link and this will give a final price for all items.

  Create a web site for an apple farm

Create a web site for an apple farm. Create an HTML5 form allowing visitors to create an account with the site. Account details are to be stored in your MySQL database. Information should be stored in a secure way.

  Develop a dynamic website open university

Develop a dynamic website Open University

  Sample website project

This website consists of three sections: a narrative, a storyboard, and a business Website.

  Online banking application

Designing and developing a web applications The company you are working has secured a contract with a local banking group to develop an ONLINE BANKING APPLICATION using PHP and MySQL.

  Design a dynamic database

Design a dynamic database using Mangodb, html , and php.

  Show the accessibility and usability of website

The webpage must have several menus about country Azerbaijan such as "About Azerbaijan" "History" "Geography" "Landscape" and "Accessibility" menu.

  Implement a web application

Implement a web application called CS320Starter, which is similar to the crowd funding platform Kickstarter where people raise funds for their projects.

  Prepare an ajax enabled web form

Prepare an AJAX enabled web form utilising a ListView control that will allow logged-in staff to list, edit, delete, insert magazine details for magazines from a selected magazine category.

  Create a very simple order system as a web application

Create a very simple Order System as a web application.

  Which of the following jsp expressions is valid

A JSP expression can contain any Java expression that evaluates to a String object, Java object, primitive type, primitive type or Java object

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd