Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

post all codes pls Post all codes please!! This assignment is based on the bakery from Assignment 2. In this assignment, we will assume all

post all codes pls image text in transcribed

Post all codes please!!

This assignment is based on the bakery from Assignment 2. In this assignment, we will assume all baker items cost $9.99.

1) The bakery has a discount scheme depending on the number of bakery items purchased. For example, It between one to three bakery items are purchased, each costs the regular price of $9.99. If between four to ten candies are purchased, the first three cost $9.99 and then the discount for the rest is 10%. It 11 or more are purchased, the tirst three items cost $9.99 each, the discount for the next 8 candies 3r to fut candies) Is 10%, and that for the remaining candies (11th onwards) is 20%. However, each order is restricted to only 50 bakery items, due to baking constraints. hence customers cannot order more than 50 items at a time Delivery is free for orders that cost more than $100. For orders less than $100, the cost of delivery is $10. In-store Dick-un is tree. Hence. for example. it a customer orders 12 bakery items. the tota due would be 99 + 7*(9.99-(0.1*9.99)) + 2*(9.99-(0.2*9.99)) = $108.90. Create a bakery order form that asks the customer for their name, address, the number of bakery items they would like to order and allows them to choose whether they would like to have the order picked-up or delivered. Placing an order should lead to a confirmation page which displays the following: The customer's tul name and address

The number of bakery items ordered

The mode of delivery selected (delivery or pick-up)

The subtotal due after applicable discounts are applied

The total amount due after adding the subtotal from above, any delivery tees it

applicable) and an additional 10% sales tax, shown to 2 decimal places.

Make sure to check for blank inputs or error inputs in the order form, and give appropriate error or warning messages in each case.

(25 points)

2 The bakery wants all orders saved in a flat file. For each order, save the tollowing information:

The order date

The customer name The total amount in the receipt

The text file should be named "bakery.txt" and saved within your htdocs folder (inside the same subfolder the PHP script is in). Each of the above fields should be separated by semi-colons. Each new order should be appended on a new line every time a customer submits the order form. Make sure to use appropriate open/close, lock unlock tunctions and modes, and show error messages when needed.

(15 points)

What to Submit to D2L?

Submit the following two files to the assigned D2L assignment space.

  1. Zip up (compress) all your source code files (e.g. HTML, CSS, PHP, etc.) for your website. Submit the zip file to D2L.
  2. Capture screenshots of each page with your own inputs and displayed outputs, including the output on the text file. Place these screenshots on a PowerPoint or Word document, and submit the file on D2L. Do NOT include this document in the above zip file - submit the document as a separate file into the D2L assignment space.

Note: This is so that in case your website does not show up correctly on my end, I can view your screenshots from within D2L. If no file with screenshots is included in the submission (-4 points), if document is mistakenly placed within the zip file (-2 points).

METROPOLITAN STATE UNIVERSITY iCs 325, 1nce raet Arilication Developant SPAEGC20z3 - ASSICNMENT-1 Her esarsit. aldines. the deusesi fer the pot in iert: (tle ensinin) is 2bre if mat se deerry is $ th in-sier pik-ig in hey 6. The coctamers fill mene and adden Make a-y be check for blank ingun ar ertar liqus in the irder farm, and pere infermation e. The ender date = The cusbont nime - The bisal asenen ie the ime eigr What te Sulmit le D2L? Bebinin the sipe fier be Dil. the decuinat an a aplatate filile inte the DeCl, anateonsut apate. (-2 peiate)

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image_2

Step: 3

blur-text-image_3

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

How To Build A Million Dollar Database

Authors: Michelle Bergquist

1st Edition

0615246842, 978-0615246840

More Books

Students also viewed these Databases questions