-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathscript.js
27 lines (25 loc) · 1.01 KB
/
script.js
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
//############################################################//
// Increment Element Function
//############################################################//
function increment(element) {
element.innerText++;
}
//############################################################//
// Hide Element Function
//############################################################//
function hide(element) {
element.remove();
}
//############################################################//
// Alert Function
//############################################################//
function selectChange(element) {
if (element.options[element.selectedIndex].value == 'Cat')
alert('You are looking for a cat');
if (element.options[element.selectedIndex].value == 'Dog')
alert('You are looking for a dog');
if (element.options[element.selectedIndex].value == 'Bunny')
alert('You are looking for a bunny');
if (element.options[element.selectedIndex].value == 'Bird')
alert('You are looking for a Bird');
}