-
Notifications
You must be signed in to change notification settings - Fork 6
/
Copy pathmedia.php
executable file
·56 lines (54 loc) · 1.16 KB
/
media.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
<?php
require 'datafetch.php';
$media = $player_inventory['MEDIA'];
$total = 0;
?>
<div class="row">
<div class="col-sm-10 col-sm-offset-1">
<div class="row">
<?php
foreach ($media as $lvl => $m){
if($m['count']> 0){
$total += $m['count'];
if(stristr($m['url'], 'youtube')){
$data = 'media';
} else {
$data ='image';
}
echo '
<div class="col-xs-6 col-sm-4 col-md-4 col-lg-4">
<div class="thumbnail media">
<a class="medias" rel="gallery" target="_blank" href="'.$m['url'].'" title="'.$m['name'].'"><img src="'.$m['image'].'" /></a>
<div class="caption">
<p class="text-center"><a class="medias" target="_blank" href="'.$m['url'].'">'.$m['name'].'</a></p>
</div>
</div>
</div>';
}
}
echo '
<hr class="col-sm-10 col-sm-offset-1" />';
echo '
<table class="table table-condensed">
<tbody>
<tr>
<td>Total </td>
<td>'.$total.'</td>
</tr>
</tbody>
</table>';
?>
</div>
<script type="text/javascript">
$(document).ready(function(){
$(".medias").fancybox({
openEffect : 'elastic',
closeEffect : 'elastic',
padding: 4,
loop: false,
helpers : {
media: {}
}
});
});
</script>