-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathactivities.js
120 lines (110 loc) · 3.33 KB
/
activities.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
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
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
$(document).ready(function(){
$("#wiki").click(function(){
window.open ("http://en.wikipedia.org/wiki/Hacker_(hobbyist)");
});
$('a:not(".signed")').click(function(){
alert("大爷~别着急,还没做呢!");
});
$('#search').click(function(){
alert("大爷~别着急,还没做呢!");
});
var pics=document.getElementById("pics");
function pic_init(){
var mybutton=document.getElementById("button1");;
mybutton.setAttribute("class","btn btn-default");
mybutton=document.getElementById("button2");;
mybutton.setAttribute("class","btn btn-default");
mybutton=document.getElementById("button3");;
mybutton.setAttribute("class","btn btn-default");
mybutton=document.getElementById("button4");;
mybutton.setAttribute("class","btn btn-default");
mybutton=document.getElementById("button5");;
mybutton.setAttribute("class","btn btn-default");
mybutton=document.getElementById("button6");;
mybutton.setAttribute("class","btn btn-default");
mybutton=document.getElementById("button7");;
mybutton.setAttribute("class","btn btn-default");
}
$('#button1').click(function(){
pic_init();
pics.setAttribute("src","image/1.jpg");
var mybutton=document.getElementById("button1");;
mybutton.setAttribute("class","btn btn-default active");
});
$('#button2').click(function(){
pic_init();
pics.setAttribute("src","image/2.jpg");
var mybutton=document.getElementById("button2");;
mybutton.setAttribute("class","btn btn-default active");
});
$('#button3').click(function(){
pic_init();
pics.setAttribute("src","image/3.jpg");
var mybutton=document.getElementById("button3");;
mybutton.setAttribute("class","btn btn-default active");
});
$('#button4').click(function(){
pic_init();
pics.setAttribute("src","image/4.jpg");
var mybutton=document.getElementById("button4");;
mybutton.setAttribute("class","btn btn-default active");
});
$('#button5').click(function(){
pic_init();
pics.setAttribute("src","image/5.jpg");
var mybutton=document.getElementById("button5");;
mybutton.setAttribute("class","btn btn-default active");
});
$('#button6').click(function(){
pic_init();
pics.setAttribute("src","image/6.jpg");
var mybutton=document.getElementById("button6");;
mybutton.setAttribute("class","btn btn-default active");
});
$('#button7').click(function(){
pic_init();
pics.setAttribute("src","image/7.jpg");
var mybutton=document.getElementById("button7");;
mybutton.setAttribute("class","btn btn-default active");
});
});
/*
var beyond = {
formedIn:'1983',
foundedIn:'xianggang',
artist:['huang','huang','huang','ye']
};
beyond['foundedIn'] = 'Ïã¸Û';
beyond.show = function(){
for(var i=0;i<this.artist.length;i++)
document.writeln(this.artist[i]);
};
beyond.show();
var property;
for(property in beyond){
if(typeof beyond[property] !== 'function')
console.log(beyond[property]);
}
*/
//console.log(beyond);
/*
window.onload = function(){
var glyphicon = document.querySelector('.glyphicon');
function showMessage(event){
console.log(event);
}
btn.addEventListener('click',showMessage,false);
glyphicon.onclick = function(){
console.log('clicked!');
}
btn.onmouseout = function(){
console.log('left');
}
glyphicon.onmouseover = function(){
console.log('who is upside?');
}
$('#joinin').bind('click',function(){
alert('想加入就来找我们啊!!');
});
}
*/