-
Notifications
You must be signed in to change notification settings - Fork 9
Expand file tree
/
Copy pathdefault.html
More file actions
129 lines (110 loc) · 4.46 KB
/
Copy pathdefault.html
File metadata and controls
129 lines (110 loc) · 4.46 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
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
121
122
123
124
125
126
127
128
129
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<meta name="viewport" content="width=device-width">
<title>{{ site.title }}{% if page.title %} : {{ page.title }}{% endif %}</title>
<meta name="description" content="{{ site.subtitle }}">
<link href="//netdna.bootstrapcdn.com/twitter-bootstrap/2.3.2/css/bootstrap-combined.no-icons.min.css" rel="stylesheet">
<link rel="stylesheet" href="{{ site.baseurl }}/css/syntax.css">
<link rel="stylesheet" href="{{ site.baseurl }}/css/main.css">
{% seo %}
</head>
<body>
<a href="https://github.com/pippo-java/pippo">
<img style="position: absolute; top: 0; right: 0; border: 0; z-index: 10000;"
src="https://github.blog/wp-content/uploads/2008/12/forkme_right_gray_6d6d6d.png"
alt="Fork me on GitHub">
</a>
<div class="container">
<div class=row-fluid>
<div id=header class=span12>
{% include header.html %}
</div>
</div>
<div class=row-fluid>
{% assign post_count = site.posts|size %}
{% if site.navigation != 0 and site.navigation == 1 or post_count > 0 %}
<div id=navigation class=span2>
{% include navigation.html %}
</div>
<div id=content class=span10>
{{ content }}
</div>
{% else %}
<div id=content class=span12>
{{ content }}
</div>
{% endif %}
</div>
{% if page.disqus == 1 %}
<div class=row-fluid>
{% if site.navigation == 1 or post_count > 0 %}
<div id=navigation class=span2></div>
<div id=disqus class=span10>
{% include disqus.html %}
</div>
{% else %}
<div id=disqus class=span12>
{% include disqus.html %}
</div>
{% endif %}
</div>
{% endif %}
<div class=row-fluid>
<div id=footer class=span12>
{% include footer.html %}
</div>
</div>
</div>
<script>
function orderNav() {
var list,
section,
header,
sections = [],
lists = {},
headers = {};
var locationObj = document.location.href;
var navUl = document.querySelectorAll('#navigation ul')[0],
navLis = document.querySelectorAll('#navigation ul li');
if (!navUl) return;
for (var i = 0; i < navLis.length; i++) {
var order, li = navLis[i];
if (li.classList.contains('nav-header')) {
section = li.textContent || li.innerText;
sections.push(section);
headers[section] = li;
continue;
}
var link = li.childNodes[0];
if (locationObj && link && locationObj.endsWith(link.getAttribute('href'))) {
li.classList.add('active');
}
if (!lists[section]) {
lists[section] = [];
}
order = parseFloat(li.getAttribute('data-order'))
lists[section].push([order, li]);
}
for (var i = 0; i < sections.length; i++) {
section = sections[i];
list = lists[section].sort(function(a, b) {
return a[0] - b[0];
});
if (header = headers[section]) {
navUl.appendChild(header);
}
for (var j = 0; j < list.length; j++) {
navUl.appendChild(list[j][1]);
}
}
}
if (document.querySelectorAll) orderNav();
</script>
{% if site.google_analytics_id != "" %}
{% include google_analytics.html %}
{% endif %}
</body>
</html>