-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathslides.php
executable file
·68 lines (62 loc) · 1.77 KB
/
slides.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
<html>
<head>
<meta charset="utf-8">
<title>Pictures</title>
<link href="css/main.css" rel="stylesheet">
<link href="css/slides.css" rel="stylesheet">
<link href="jqui/themes/ui-darkness/jquery-ui.css" rel="stylesheet">
<link href="css/slidesoverride.css" rel="stylesheet">
<script src="jqui/jquery-1.9.0.js"></script>
<script src="jqui/ui/jquery-ui.js"></script>
<script src="scripts/main.js"></script>
<script src="scripts/jquery.cycle.all.js"></script>
</head>
<body>
<?php
require 'crypt.php';
$config = parse_ini_file("config.ini");
$cryptpw = $config["cryptpw"];
if (isset($_GET['album'])) {
$encalbum = urldecode($_GET['album']);
$album = decrypt($encalbum, $cryptpw);
}
$picPath = "Pics/$album/*.[jJ][pP][gG]";
$files = glob($picPath);
$numfiles = count($files);
?>
<div id="container">
<?php
for ($i=0; $i < $numfiles; $i++)
{
$onefile = $files[$i];
?>
<div><img class="slide" src="<?php echo $onefile; ?>" /></div>
<?php
}
?>
</div>
<button id="browse">Browse</button>
<div id="thumbs" class="ui-widget">
<div id="content" class="ui-widget-content">
<?php
for ($i=0; $i < $numfiles; $i++)
{
$onefile = $files[$i];
?>
<div class="thumb">
<img class="thumb" src="<?php echo $onefile; ?>" />
</div>
<?php
}
?>
</div>
</div>
<div id="tb-container" class="ui-widget-overlay ui-corner-all">
<span id="controltoolbar" class="ui-widget-header ui-corner-all">
<button id="prev">Previous</button>
<button id="play">Pause</button>
<button id="next">Next</button>
</span>
</div>
</body>
</html>