forked from justdeleteme/justdelete.me
-
Notifications
You must be signed in to change notification settings - Fork 0
/
dev.php
387 lines (353 loc) · 16.2 KB
/
dev.php
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
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
<?php
$sites = json_decode(file_get_contents('sites.json'));
usort($sites, function($a, $b) {
$a = strtolower($a->name);
$b = strtolower($b->name);
if ($a < $b) return -1;
if ($a > $b) return 1;
return 0;
});
// For testing
if ( ! isset($contributors))
{
$contributors = "";
}
if (isset($_GET['lang']))
{
$lang = $_GET['lang'];
// For Right-To-Left Languages
$rtl = ($lang == "fa" || $lang == "ar") ? true : false;
}
// For testing
if ( !isset($lang))
{
$lang = "en";
$rtl = false;
}
if ( !isset($full_name))
{
$full_name = "English";
}
$definitions = json_decode(file_get_contents('trans/site/'.$lang.'.json'));
// var_dump($definitions);
// die;
$title = $definitions->title;
$description = $definitions->description;
$difficulty = $definitions->difficulty;
$difficulty_easy = $definitions->difficulty_easy;
$difficulty_medium = $definitions->difficulty_medium;
$difficulty_hard = $definitions->difficulty_hard;
$difficulty_impossible = $definitions->difficulty_impossible;
$tagline = $definitions->tagline;
$noinfo = $definitions->noinfo;
$showinfo = $definitions->showinfo;
$hideinfo = $definitions->hideinfo;
$whatisthis = $definitions->whatisthis;
$whatisthis1 = $definitions->whatisthis1;
$whatisthis2 = $definitions->whatisthis2;
$whatisthis3 = $definitions->whatisthis3;
$guide = $definitions->guide;
$guideexplanations = $definitions->guideexplanations;
$guideeasy = $definitions->guideeasy;
$guidemedium = $definitions->guidemedium;
$guidehard = $definitions->guidehard;
$guideimpossible = $definitions->guideimpossible;
$translationcontrib = $definitions->translationcontrib;
$morecontrib = $definitions->morecontrib;
$viewcontrib = $definitions->viewcontrib;
$extensionguide = $definitions->extensionguide;
$extension = $definitions->extension;
$extensionp1 = $definitions->extensionp1;
$extensionp2 = $definitions->extensionp2;
$extensionp3 = $definitions->extensionp3;
$extensionl1 = $definitions->extensionl1;
$extensionl2 = $definitions->extensionl2;
$extensionl3 = $definitions->extensionl3;
$extensionl4 = $definitions->extensionl4;
$banner = $definitions->banner;
$footer = $definitions->footer;
$help_translate = $definitions->help;
$donate = $definitions->donate;
$sendmail = $definitions->sendmail;
$submit = $definitions->submit;
$popular = $definitions->popular;
if ($lang == "en")
{
$note_lang = "notes";
}
else
{
$note_lang = "notes_" . $lang;
}
$homepage = true;
?>
<?php include('inc/header.php'); ?>
<div class="search">
<div class="search-container">
<input type="text" id="search">
<a href="#">search</a>
</div>
<div class="sort-container">
<button class="popular"><?php echo $popular; ?></button>
<button data-dropdown="#dropdown-2" class="az-sort">A - Z</button>
<button data-dropdown="#dropdown-3" class="diff-sort"><?php echo $difficulty; ?></button>
<button class="reset">reset</button>
</div>
</div>
<section class="main">
<section class="adsense">
<script async src="//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js"></script>
<!-- JDM -->
<ins class="adsbygoogle"
style="display:inline-block;width:728px;height:90px"
data-ad-client="ca-pub-9778304973218149"
data-ad-slot="6251902116"></ins>
<script>
(adsbygoogle = window.adsbygoogle || []).push({});
</script>
</section>
<section class="sites" id="sites">
<p class="no-results">Can't find what you're looking for? <a href='http://github.com/rmlewisuk/justdelete.me'>Help make justdelete.me better</a>.</p>
<!-- // FIRST FOR EACH -->
<?php foreach ($sites as $site) : ?><section class="site-block <?php echo $site->difficulty; ?>">
<a class="site-header" href="<?php echo $site->url; ?>">
<?php echo $site->name; ?>
</a>
<p class="site-difficulty">
<?php echo eval('return $difficulty_' . $site->difficulty . ';'); ?>
</p>
<?php if (isset($site->$note_lang)) : ?>
<div class="tooltip-content">
<?php echo $site->$note_lang;
if (isset($site->email))
{
echo '<br><a href="mailto:' . $site->email . '?Subject=Account%20Deletion%20Request&body=Please%20delete%20my%20account,%20my%20username%20is%20 XXXXXX">' . $sendmail . ' »</a>';
}
?>
</div>
<a href="#" class="tooltip-toggle contains-info"><?php echo $showinfo ?></a>
<?php elseif (isset($site->notes)) : ?>
<div class="tooltip-content">
<?php echo $site->notes;
if (isset($site->email))
{
echo '<br><a href="mailto:' . $site->email . '?Subject=Account%20Deletion%20Request&body=Please%20delete%20my%20account,%20my%20username%20is%20 XXXXX">' . $sendmail . ' »</a>';
}
?>
</div>
<a href="#" class="tooltip-toggle contains-info"><?php echo $showinfo ?></a>
<?php else : ?>
<p class="tooltip-toggle"><?php echo $noinfo ?></p>
<?php endif; ?>
<?php if (isset($site->meta)) : ?>
<span class="meta"><?php echo $site->meta; ?></span>
<?php endif; ?>
</section><?php endforeach; ?>
</section>
</section>
<span id="about">about anchor</span>
<section class="adsense">
<script async src="//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js"></script>
<!-- JDM -->
<ins class="adsbygoogle"
style="display:inline-block;width:728px;height:90px"
data-ad-client="ca-pub-9778304973218149"
data-ad-slot="6251902116"></ins>
<script>
(adsbygoogle = window.adsbygoogle || []).push({});
</script>
</section>
<section class="info-block about">
<div class="info-container">
<div class="info-block-half">
<h2><?php echo $whatisthis ?></h2>
<p><?php echo $whatisthis1 ?></p>
<p><?php echo $whatisthis2 ?></p>
<p><a target="_blank" href="https://docs.google.com/a/therobb.com/forms/d/1mhr3vaTni5U8PvOdp_NvQ6vKBxNTmJTeKP3VWRuioCE/viewform"><?php echo $submit ?> »</a></p>
<ul>
<li><a href="http://robblewis.me/just-delete-me?utm_source=JustDeleteMe&utm_medium=link&utm_campaign=Just+Delete+Me" target="_blank">Read the announcement blog post »</a></li>
<li><a href="http://robblewis.me/24-hours-of-just-delete-me/" target="_blank">See the first-day stats »</a></li>
<li><a href="http://thetechtailor.com/justdeleteme" target="_blank">Listen to an interview with Robb on The Tech Tailor podcast »</a></li>
<li><a href="http://robblewis.me/just-delete-me-one-million-page-views/">One Million Page Views »</a></li>
</ul>
<p><a href="https://twitter.com/justdeletedotme" class="twitter-follow-button" data-show-count="false" data-size="large">Follow @justdeletedotme</a></p>
</div><div class="info-block-half">
<h2><?php echo $guide ?></h2>
<p><?php echo $guideexplanations ?></p>
<ul>
<li><?php echo $guideeasy ?></li>
<li><?php echo $guidemedium ?></li>
<li><?php echo $guidehard ?></li>
<li><?php echo $guideimpossible ?></li>
</ul>
<p><?php echo $donate; ?></p>
<form action="https://www.paypal.com/cgi-bin/webscr" method="post" target="_top">
<input type="hidden" name="cmd" value="_s-xclick">
<input type="hidden" name="hosted_button_id" value="E9VLGMSJ3R4Q4">
<input type="image" src="https://www.paypalobjects.com/en_GB/i/btn/btn_donate_SM.gif" border="0" name="submit" alt="PayPal – The safer, easier way to pay online.">
<img alt="" border="0" src="https://www.paypalobjects.com/en_GB/i/scr/pixel.gif" width="1" height="1">
</form>
</div>
</div>
</section>
<section class="info-block contributors">
<div class="info-container">
<div class="info-block-half">
<h2><?php echo $translationcontrib; ?></h2>
<ul class="contributors translate">
<li class="ar"><a href="https://github.com/adahhane">Dahhane Ayyoub</a></li>
<li class="cat"><a href="https://github.com/rockbdn">JP Queralt (+ Español)</a></li>
<li class="de"><a href="http://www.erbloggt.de/">Konstantin Hinrichs</a></li>
<li class="de"><a href="http://www.floriankeller.de/">Florian Keller</a></li>
<li class="fa"><a href="https://github.com/Arasteh">Mahmoud Arasteh Nasab</a></li>
<li class="fa"><a href="https://github.com/MHM5000">Mohammad Hossein Mojtahedi</a></li>
<li class="fr"><a href="https://github.com/buzzb0x">Ethan Ohayon</a></li>
<li class="fr"><a href="https://github.com/p1rox">Armand Vignat</a></li>
<li class="id"><a href="https://github.com/rafeyu">Ramdziana Feri Y</a></li>
<li class="it"><a href="https://github.com/LorenzoRogai">Lorenzo Rogai</a></li>
<li class="nl"><a href="https://github.com/mprins">Mark Prins</a></li>
<li class="pt_br"><a href="https://github.com/mkbu95">Matheus Macabu</a></li>
<li class="ro"><a href="https://github.com/teofilcojocariu">Teofil Cojocariu</a></li>
<li class="ru"><a href="https://github.com/morozd">morozd</a></li>
<li class="tr"><a href="https://github.com/MarioErmando">Erman Sayın</a></li>
<li class="vi"><a href="https://github.com/giangnb">Giang Nguyen</a></li>
<li class="zh-cn"><a href="https://github.com/Jonwei">Joe Shen</a></li>
<li class="zh-tw"><a href="https://github.com/CalvertYang">Calvert</a></li>
<li class="pl"><a href="https://github.com/Halamix2">Piotr Halama</a></li>
</ul>
</div><div class="info-block-half">
<h2><?php echo $morecontrib; ?></h2>
<?php echo $contributors; ?>
<p><br/><a href='http://github.com/rmlewisuk/justdelete.me/contributors'><?php echo $viewcontrib; ?> »</a></p>
</ul>
</div>
</div>
</section>
<div class="banner-block">
<div class="banner-content">
<div class="banner-block-half">
<h2><?php echo $extension ?></h2>
<p><?php echo $extensionp1 ?></p>
<p><?php echo $extensionp2 ?></p>
<p><?php echo $extensionp3 ?></p>
</div><div class="banner-block-half">
<h2><?php echo $extensionguide; ?></h2>
<ul>
<li><?php echo $extensionl1 ?></li>
<li><?php echo $extensionl2 ?></li>
<li><?php echo $extensionl3 ?></li>
<li><?php echo $extensionl4 ?></li>
</ul>
</div>
</div>
<div class="banner-block-extension"></div>
</div>
<section class="info-block">
<div class="info-container">
<footer>
<span><?php echo $footer ?></span>
<div class="share-buttons<?php echo ($rtl) ? ' share-buttons-rtl' : '' ; ?>" id="share buttons">
<!-- Twitter -->
<a href="https://twitter.com/share" class="twitter-share-button" data-url="http://justdelete.me">Tweet</a>
<script>!function(d,s,id){var js,fjs=d.getElementsByTagName(s)[0],p=/^http:/.test(d.location)?'http':'https';if(!d.getElementById(id)){js=d.createElement(s);js.id=id;js.src=p+'://platform.twitter.com/widgets.js';fjs.parentNode.insertBefore(js,fjs);}}(document, 'script', 'twitter-wjs');</script>
<!-- Facebook -->
<div class="fb-like" data-href="http://justdelete.me" data-width="450" data-colorscheme="dark" data-layout="button_count" data-show-faces="false" data-send="false"></div>
</div>
</footer>
</div>
</section>
<script type="text/javascript">
$('.contains-info').click(function(e) {
e.preventDefault();
if ($(this).prev().hasClass('toggled')) {
if ($(this).hasClass('text-toggled')) {
$(this).html("<?php echo $showinfo ?>").removeClass('text-toggled');
} else {
$(this).html("<?php echo $showinfo ?>").removeClass('text-toggled');
}
$(this).prev().slideToggle().removeClass('toggled');
} else {
$('.toggled').next().html("<?php echo $showinfo ?>");
$('.toggled').slideToggle().removeClass('toggled');
$(this).prev().slideToggle().addClass('toggled');
$(this).html("<?php echo $hideinfo ?>").addClass('text-toggled');
}
});
</script>
<div id="dropdown-1" class="dropdown dropdown-tip has-icons">
<ul class="dropdown-menu">
<li class="en"><a href="/">English</a></li>
<li class="it"><a href="it.html">Italiano</a></li>
<li class="de"><a href="de.html">Deutsch</a></li>
<li class="fr"><a href="fr.html">Français</a></li>
<li class="nl"><a href="nl.html">Nederlands</a></li>
<li class="es"><a href="es.html">Español</a></li>
<li class="cat"><a href="cat.html">Català</a></li>
<li class="pt_br"><a href="pt_br.html">Português</a></li>
<li class="ru"><a href="ru.html">Pусский</a></li>
<li class="vi"><a href="vi.html">Tiếng Việt</a></li>
<li class="tr"><a href="tr.html">Türk</a></li>
<li class="ar"><a href="ar.html">العربية</a></li>
<li class="fa"><a href="fa.html">فارسی</a></li>
<li class="zh-cn"><a href="zh-cn.html">中国的</a></li>
<li class="zh-tw"><a href="zh-tw.html">正體中文</a></li>
<li class="id"><a href="id.html">Indonesia</a></li>
<li class="ro"><a href="ro.html">Român</a></li>
<li class="pl"><a href="pl.html">Polski</a></li>
<li class="dropdown-divider"></li>
<li class="help"><a target="_blank" href="https://github.com/rmlewisuk/justdelete.me/issues/164"><?php echo $help_translate; ?></a></li>
</ul>
</div>
<div id="dropdown-2" class="dropdown dropdown-tip">
<ul class="dropdown-menu ltr">
<span class="alpha-sort">
<li><a href="#">a</a></li>
<li><a href="#">b</a></li>
<li><a href="#">c</a></li>
<li><a href="#">d</a></li>
<li><a href="#">e</a></li>
<li><a href="#">f</a></li>
<li><a href="#">g</a></li>
<li><a href="#">h</a></li>
<li><a href="#">i</a></li>
<li><a href="#">j</a></li>
<li><a href="#">k</a></li>
<li><a href="#">l</a></li>
<li><a href="#">m</a></li>
<li><a href="#">n</a></li>
<li><a href="#">o</a></li>
<li><a href="#">p</a></li>
<li><a href="#">q</a></li>
<li><a href="#">r</a></li>
<li><a href="#">s</a></li>
<li><a href="#">t</a></li>
<li><a href="#">u</a></li>
<li><a href="#">v</a></li>
<li><a href="#">w</a></li>
<li><a href="#">x</a></li>
<li><a href="#">y</a></li>
<li><a href="#">z</a></li>
</span>
</ul>
</div>
<div id="dropdown-3" class="dropdown dropdown-tip">
<ul class="dropdown-menu">
<span class="diff-sort">
<?php
if ($lang != "zh-tw" && $lang != "zh-cn") {
?>
<li><a href="#"><?php echo ucfirst($difficulty_easy); ?></a></li>
<li><a href="#"><?php echo ucfirst($difficulty_medium); ?></a></li>
<li><a href="#"><?php echo ucfirst($difficulty_hard); ?></a></li>
<li><a href="#"><?php echo ucfirst($difficulty_impossible); ?></a></li>
<?php } else { ?>
<li><a href="#"><?php echo $difficulty_easy; ?></a></li>
<li><a href="#"><?php echo $difficulty_medium; ?></a></li>
<li><a href="#"><?php echo $difficulty_hard; ?></a></li>
<li><a href="#"><?php echo $difficulty_impossible; ?></a></li>
<?php } ?>
</span>
</ul>
</div>
</body>
</html>