-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
168 lines (148 loc) · 5.9 KB
/
index.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
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
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
<!--
###############################################
# @Author : Jason
# @Contact : casjaysdev@casjay.pro
# @File : index
# @Created : 23/07/2020
# @License : WTFPL
# @Copyright : Copyright (c) CasjaysDev
# @Description :
###############################################
-->
<!DOCTYPE html>
<html lang="en-US">
<head>
<link rel="shortcut icon" href="https://casjaysdev-sites.github.io/static/favicon.ico" />
<link rel="stylesheet" type="text/css" href="https:///static.casjay.pro/default-css/casjaysdev.css">
<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.2.4/jquery.min.js"></script>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script>>
<meta charset='utf-8'>
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="generator" content="CasjaysDev">
<title>CasjaysDev Static Site</title>
</head>
<body>
<!-- Begin Body -->
<p align="center">"<h1>Memes</h1></p>
<ul id="users"></ul>
<script>
// GitHub API URL
const url = 'https://api.github.com/repos/onhealth/memes/contents/images';
// create an element
const createNode = (elem) => {
return document.createElement(elem);
};
// append an element to parent
const appendNode = (parent, elem) => {
parent.appendChild(elem);
}
// List Element
const ul = document.querySelector('#users');
// make the API call
fetch(url)
.then(res => res.json())
.then(data => {
console.log(data)
// iterate over users
data.map((user) => {
// create the elements
let li = createNode('li'),
img = createNode('img'),
span = createNode('span');
img.src = user.download_url;
span.innerText = user.name;
// append all elements
appendNode(li, img);
appendNode(li, span);
appendNode(ul, li);
});
}).catch(err => {
console.error('Error: ', err);
});
</script>
<noscript>Sorry, your browser does not support JavaScript!</noscript>
<!-- End Body -->
<p align="center">
<!-- Begin Footer -->
<footer>
<center>
<!-- Begin Google Track -->
<script async src="https://www.googletagmanager.com/gtag/js?id=UA-936146-14"></script>
<script>
window.dataLayer = window.dataLayer || [];
function gtag() {
dataLayer.push(arguments);
}
gtag('js', new Date());
gtag('config', 'UA-936146-14');
</script>
<!-- Eng Google Track --><br>
<!-- Begin EU compliant -->
<link rel="stylesheet" type="text/css"
href="https://cdnjs.cloudflare.com/ajax/libs/cookieconsent2/3.0.3/cookieconsent.min.css" />
<script src="https://cdnjs.cloudflare.com/ajax/libs/cookieconsent2/3.0.3/cookieconsent.min.js"></script>
<script>
window.addEventListener("load", function () {
window.cookieconsent.initialise({
"palette": {
"popup": {
"background": "#64386b",
"text": "#ffcdfd"
},
"button": {
"background": "transparent",
"text": "#f8a8ff",
"border": "#f8a8ff"
}
},
"content": {
"message": "In accordance with the EU GDPR law this message is being displayed. - ",
"dismiss": "I Agree",
"link": "CasjaysDev Policy",
"href": "https://casjay.pro/privacy"
}
})
});
</script>
<!-- End EU compliant --><br>
<!-- Begin Casjays Developments Footer -->
<h6>
Copyright 1999 - 2020<br>
<a href="https://casjay.pro" target="_blank">Casjays Developments</a> and <a href="https://malaks-us.github.io/jason"
target="_blank">Jason M. Hempstead-Malak</a><br>
Hosting by <a href="https://casjay.pro/hosting" target="_blank">Casjays Developments: Hosting</a><br>
and powered by <a href="https://casjaysdev.pro" target="_blank">CasjaysDev.pro</a><br><br>
<a href="https://help.casjay.pro" target="_blank">CasjaysDev Support</a> |
<a href="https://bugs.casjay.pro" target="_blank">CasjaysDev Bugs</a> <br>
<a href="https://status.casjay.pro" target="_blank">System Status</a> |
<a href="https://servers.casjay.pro" target="_blank">Service Status</a> |
<a href="https://status.casjaysdev.pro" target="_blank">Complete Status</a> <br>
<a href="https://casjaysdev.pro/domains.html" target="_blank">Casjays Developments Domains</a>
<br><br>
Casjays Developments privacy policy can be found at<br>
<a href="https://casjaysdev.pro/policy/" target="_blank">https://casjaysdev.pro/policy</a><br>
<br>
<br>
</h6>
<!-- End Casjays Developments Footer -->
<br>
<!-- Begin Statcounter Code -->
<script type="text/javascript">
var sc_project = 8585230;
var sc_invisible = 0;
var sc_security = "ef07ac24";
var scJsHost = (("https:" == document.location.protocol) ?
"https://secure." : "http://www.");
document.write("<sc" + "ript type='text/javascript' src='" +
scJsHost +
"statcounter.com/counter/counter.js'></" + "script>");
</script>
<!-- End Statcounter Code --><br>
<br>
<br><br><br><br>
</center>
</footer>
<!-- End Footer -->
</body>
</html>