-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathgallary.php
68 lines (56 loc) · 1.31 KB
/
gallary.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
<?php
session_start();
include_once('/lib/feeder.php');
$_SESSION['pre_fix'] = "";//Path pre_fix
Head_Section();
?>
<body>
<script type="text/javascript">
<?php
include_once('/lib/js_feeder.php');
JQ_DocReady_Start();
SliderJS();
NavigationBarJS();
JQ_DocReady_End();
ValidateForm('frmLog');
?>
</script>
<div id='wrapper'>
<?php
PageHeading("Success Enterprise");
NavigationBar("Gallary");
Slider();
include_once('/lib/helper.php');
$directory = $_SERVER["DOCUMENT_ROOT"] . "/SuccessEnterprise/img/gallary/";
$files = array_diff(scandir($directory), array('..', '.'));
$n = 1;
$div_open = false;
$new = false;
echo "<div id='div_gal'>";
foreach($files as $f){
if(is_file($directory . $f )) {
if($n==1){/*This group each 4 gal items together, this is nesassary
place fotter in proper place*/
echo "<div id='div_gal_con'>";
$div_open = true;
}
echo "<div id='div_gal_item'>
<p>". IsNewItem($f,$new) . "</p>
<img id='div_gal_img' src='img/gallary/" . $f . "'/>";
if($new)//New item
echo "<img id='new_overlay' src='img/new.png'/>";
echo "</div>";
if($n++==4){
echo "</div>";
$n = 1;
$div_open = false;
}
}
}
if($div_open)echo "</div>";
echo "</div>";//div_gal
?>
<?php Footer();?>
</div><!--Wrapper DIV -->
</body>
</html>