-
Notifications
You must be signed in to change notification settings - Fork 0
/
photos.html
85 lines (80 loc) · 3.34 KB
/
photos.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
82
83
84
85
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge;chrome=1">
<meta name="keywords" content="">
<title>照片集 | Sahara</title>
<link rel="stylesheet" href="//netdna.bootstrapcdn.com/bootstrap/3.1.1/css/bootstrap.min.css">
<script src="http://code.jquery.com/jquery-1.11.0.min.js"></script><script src="//netdna.bootstrapcdn.com/bootstrap/3.1.1/js/bootstrap.min.js"></script><link href="/stylesheets/all.css" media="screen" rel="stylesheet" type="text/css">
<script src="/javascripts/html5.js" type="text/javascript"></script><script src="/javascripts/jquery.wookmark.min.js" type="text/javascript"></script>
</head>
<body>
<nav class="navbar navbar-default navbar-fixed-top" role="navigation"><div class="container-fluid">
<div class="navbar-header">
<button type="button" class="navbar-toggle" data-toggle="collapse" data-target="#navbar_collapse">
<span class="sr-only">Toggle navigation</span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
<a class="navbar-brand" href="/">Sahara</a>
</div>
<div class="collapse navbar-collapse" id="navbar_collapse">
<ul class="nav navbar-nav">
<li class=""><a href="/tags/hotchpotch.html">什锦杂烩</a></li>
<li class=""><a href="/tags/tech.html">技术活呀</a></li>
<li class="active"><a href="/photos.html">美片片儿</a></li>
</ul>
<ul class="nav navbar-nav navbar-right">
<li class="">
<a href="/contact.html">
<i class="fa fa-leaf"></i> Contact Me
</a>
</li>
</ul>
</div>
</div>
</nav><div class="container-fluid">
<ul id="image_gallery">
<li class="loading">加载中...</li>
</ul>
</div>
<script type="text/javascript">
$.getJSON(
"http://api.flickr.com/services/feeds/photos_public.gne?jsoncallback=?",
{id: '34499786@N04', format: 'json'},
function (data) {
$("#image_gallery").empty();
$.each(data.items, function(i, item) {
var link = $("<a>").attr('href', item.link);
link.attr('target', '_blank');
$("<img/>").attr("src", item.media.m).appendTo(link);
$("<span>").text(item.title).appendTo(link);
$("<li>").append(link).appendTo("#image_gallery");
if ( i == 30 ) return false;
});
$("#image_gallery img").load(function() {
$(this).parents('li').siblings('li:visible').andSelf().wookmark({
container: $("#image_gallery"),
offset: 2
});
});
}
)
</script><script type="text/javascript">
var _gaq = _gaq || [];
_gaq.push(['_setAccount', 'UA-36981452-2']);
_gaq.push(['_trackPageview']);
(function () {
var ga = document.createElement('script');
ga.type = 'text/javascript';
ga.async = true;
ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
var s = document.getElementsByTagName('script')[0];
s.parentNode.insertBefore(ga, s);
})();
</script>
</body>
</html>