-
Notifications
You must be signed in to change notification settings - Fork 1
/
output.php
126 lines (104 loc) · 2.21 KB
/
output.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
<?php
$sc = 0;
foreach ($slideshow_exploded as $slide)
{
$slide_exploded = explode("|02df|", $slide);
$src = $slide_exploded[0];
$title = $slide_exploded[1];
$desc = $slide_exploded[2];
$href = $slide_exploded[3];
$slide_type = $slide_exploded[4];
if ($type == "slideshow" && $width != "" && $height != "")
{
$width_and_height = " style='width: " . $width . "px; height: " . $height . "px; '";
}
$html .= "
<div class='slide' id='sliderly_" . $id . "_" . $sc . "' " . $width_and_height . ">";
if ($slide_type == "html")
{
$html .= $src;
}
else
{
if ($colorbox == "true")
{
if ($desc != "")
{
$ddesc = " - " . $desc;
}
if ($href != "")
{
$html .= "<a href='" . $href . "' class='colorbox' title=\"" . $title . $ddesc . "\">";
}
else
{
$html .= "<a href='" . $src . "' class='colorbox' title=\"" . $title . $ddesc . "\">";
}
}
else if ($href != "")
{
$html .= "<a href='" . $href . "'>";
}
if ($type == "slideshow")
{
$html .= "
<img src='" . $src . "' alt='" . $title . "' data-desc='" . $desc . "'" . $width_and_height . " />";
}
else
{
$html .= "
<img src='" . $src . "' alt='" . $title . "' data-desc='" . $desc . "' />";
}
if ($type == "slideshow" && ($title != "" || $desc != ""))
{
$html .= "
<div class='caption' style='bottom: 5px; '>";
if ($title != "")
{
$html .= "<h2>$title</h2>";
}
if ($desc != "")
{
$html .= "<p>$desc</p>";
}
$html .= "
</div>";
}
if ($colorbox == "true")
{
if ($href != "")
{
$html .= "</a>";
}
else
{
$html .= "</a>";
}
}
else if ($href != "")
{
$html .= "</a>";
}
}
$html .= "
</div>";
$sc += 1;
}
if ($files_set != "true")
{
include("css.php");
include("js.php");
$files_set = "true";
}
$output = "
<div class='sliderly-$type sliderly-grid-$grid controls-$controls'>
<p class='sliderly-title'>$slideshow_title</p>
<div class='slides_container'>"
. $html .
"</div>";
if ($type == "gallery")
{
$output .= "<div style='clear: both; '></div>";
}
$output .= "</div>";
?>