-
Notifications
You must be signed in to change notification settings - Fork 0
/
girlChoicePage.html
81 lines (75 loc) · 3.63 KB
/
girlChoicePage.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
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
<!DOCTYPE html>
<html>
<head>
<link rel= "stylesheet" type= "text/css" href="tinderforfriends.css"/>
<script type="text/javascript" src="userName.js"></script>
<link rel="stylesheet" type="text/css" href="webpagestyle.css">
<link rel="stylesheet" type="text/css" href="https://stackpath.bootstrapcdn.com/bootstrap/4.1.3/css/bootstrap.min.css">
<script type="text/javascript" src="https://code.jquery.com/jquery-3.3.1.slim.min.js"></script>
<script type="text/javascript" src="https://stackpath.bootstrapcdn.com/bootstrap/4.1.3/js/bootstrap.bundle.min.js"></script>
<script type="text/javascript" src="tinderforfriends.js"></script>
</head>
<body onload="myFunction()">
<nav class="navbar navbar-expand-lg navbar-light bg-light fixed-top">
<div class="container">
<a class="navbar-brand" href="#">BUDDIES</a>
<button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarResponsive" aria-controls="navbarResponsive" aria-expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>
<div class="collapse navbar-collapse" id="navbarResponsive">
<ul class="navbar-nav ml-auto">
<li class="nav-item active">
<a class="nav-link" href="index.html">Home
<span class="sr-only">(current)</span>
</a>
</li>
<li class="nav-item">
<a class="nav-link" href="FinalP.html">Register</a>
</li>
<li class="nav-item">
<a class="nav-link" href="aboutPage.html">About</a>
</li>
</ul>
</div>
</div>
</nav>
<center>
<font color= "white">
<br><br><br><br><br><br><br><br><br>
<h1> Great! Here is a female friend in your area that we found for you! </h1>
<button onclick="myFunction()">Click for a new friend!</button>
<p id="demo"> </p>
<script>
function shuffle(array) {
var currentIndex = array.length, temporaryValue, randomIndex;
// While there remain elements to shuffle...
while (0 !== currentIndex) {
// Pick a remaining element...
randomIndex = Math.floor(Math.random() * currentIndex);
currentIndex -= 1;
// And swap it with the current element.
temporaryValue = array[currentIndex];
array[currentIndex] = array[randomIndex];
array[randomIndex] = temporaryValue;
}
return array;
}
function myFunction() {
var friends = ["Samantha", "Ally", "Kelly", "Sophie", "Sydney", "Laura", "Maria", "Serena", "Elizabeth", "Kristine",
"Sarah", "Katrina", "Zoey", "Kim", "Olivia", "Ava", "Emma", "Isabella", "Michelle", "Amanda", "Leah", "Savannah", "Grace",
"Melissa", "Mikayla", "Jaclyn", "Lousia", "Amelia", "Charlotte"];
var names = shuffle(friends)
var email = ["pizza123@gmail.com", "docu34@aol.com", "dogsrgr8@yahoo.com", "ilovegiraffes@gmail.com", "gbacon@mac.com","r3djack3t@yahoo.com", "friedchckn73@gmail.com", "argarnio@aol.com", "greenball00n@yahoo.com"];
var emails = shuffle(email)
document.getElementById("myText").innerHTML = names[0];
document.getElementById("myTexts").innerHTML = emails[0];
}
</script>
<h2>Your next friend is: <span id="myText"></span></h2>
<h2>Her email address is: <span id="myTexts"></span></h2>
<a href= "tinderforfriendsthree.html" ><button >Go Back</button> </a>
<a href= "index.html" ><button>Go back to main page</button> </a>
</font>
</center>
</body>
</html>