-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathLab4.html
48 lines (43 loc) · 1.91 KB
/
Lab4.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
<!DOCTYPE html>
<html lang = "en">
<head>
<title>CSC 225: Lab 4</title>
<!-- Required meta tags -->
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
<!-- Bootstrap CSS -->
<link href="https://cdn.jsdelivr.net/npm/[email protected]/dist/css/bootstrap.min.css" rel="stylesheet"
integrity="sha384-T3c6CoIi6uLrA9TneNEoa7RxnatzjcDSCmG1MXxSR1GAsXEV/Dwwykc2MPK8M2HN" crossorigin="anonymous">
<script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/js/bootstrap.bundle.min.js"
integrity="sha384-C6RzsynM9kWDrMNeT87bh95OGNyZPhcTNXj1NW7RuBCsyN/o0jlpcV8Qyq46cDfL" crossorigin="anonymous"></script>
</head>
<body>
<body>
<div class = "container">
<div class="jumbotron">
<h1 class = "display-4">CSC 225 -- Lab 4</h1>
<p class = "lead">Customer Order: (please fill out the prompt or refresh the page if there is no prompt!)</p>
</div>
<br/>
<br/>
</body>
<script type = "text/javascript">
var CustName;
var ItemName;
var Numb;
CustName = window.prompt("Please enter your name", "your name goes here");
ItemName = window.prompt("Please enter the item you'd like to purchase", "Item Name goes here");
Numb = window.prompt("How many would you like to purchase?", "Enter quantity here in numeric format, please");
if (Numb > 99)
Numb = 99;
if (Numb < 1)
Numb = 1;
Day = new Date();
Day.setDate(Day.getDate() + 7);
document.writeln("<h1> Order Successful!\n");
document.writeln("<h1> Thank you for your order, " + CustName + "</h1>");
document.writeln("<h1> You ordered: " + ItemName + "</h1>\n");
document.writeln("<h1> Quantity: " + Numb + "</h1>\n");
document.writeln("<h1> Your item should arrive on: " + Day + "</h1>\n" );
document.writeln("<h1>Have a wonderful day!</h1>");
</script>