forked from bdobry/hackathon2016
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathhead.php
More file actions
51 lines (40 loc) · 1.55 KB
/
Copy pathhead.php
File metadata and controls
51 lines (40 loc) · 1.55 KB
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
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Classmate</title>
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.2.0/css/bootstrap.min.css">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/font-awesome/4.5.0/css/font-awesome.min.css">
<link rel="stylesheet" href="css/style.css">
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.1/jquery.min.js"></script>
<script src="https://ajax.aspnetcdn.com/ajax/jquery.validate/1.11.1/jquery.validate.js"></script>
<script src="https://ajax.aspnetcdn.com/ajax/jquery.validate/1.11.1/additional-methods.js"></script>
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.2.0/js/bootstrap.min.js"></script>
<script src="js/main.js"></script>
<script>
var clicks = 0;
function myFunction() {
clicks += 1;
document.getElementById("demo").innerHTML = clicks;
changeColor();
}
function myFunctionminus() {
clicks -= 1;
document.getElementById("demo").innerHTML = clicks;
changeColor();
}
function changeColor(){
console.log($("#demo"));
if (clicks > 0) {
$("#demo").addClass('plus').removeClass('minus');
}else if(clicks < 0){
$("#demo").addClass('minus').removeClass('plus');
}else{
$("#demo").removeClass('plus minus');
}
}
</script>
</head>
<body>