summaryrefslogtreecommitdiffstats
path: root/application/views/file/fragments/thumbnail.php
blob: 402e1ac7c4c66e05397763560e4e0e7a8046de23 (plain)
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
<!-- Comment markers background: http://stackoverflow.com/a/14776780/953022 -->
<div class="container container-wide">
<?php
$base_url = site_url();
if (substr($base_url, -1) !== "/") {
	$base_url .= "/";
}
?>
<div class="upload_thumbnails"><!--
	<?php foreach($items as $key => $item): ?>
		--><a
			<?php if (strpos($item["mimetype"], "image/") === 0) {?>rel="gallery" class="colorbox"<?php } ?>
			data-orientation="<?php echo $item["orientation"]; ?>"
			href="<?php echo $base_url.$item["id"]."/"; ?>"
			title="<?php echo htmlentities($item["filename"], ENT_QUOTES); ?>"
			data-content="<?php echo htmlentities($item["tooltip"], ENT_QUOTES); ?>"
			data-id="<?php echo $item["id"]; ?>"><!--
			--><img	class="thumb lazyload"
				data-original="<?php echo $base_url."file/thumbnail/".$item["id"]; ?>"
				><!--
			--><noscript><img class="thumb" src="<?php echo $base_url."file/thumbnail/".$item["id"]; ?>"></noscript></a><!--
	<?php endforeach; ?>
	-->
</div>
</div>