2009-01-01 00:23:29 +00:00
|
|
|
<?php defined("SYSPATH") or die("No direct script access.") ?>
|
2009-06-16 17:17:39 -07:00
|
|
|
|
|
|
|
|
<? if (access::can("view_full", $theme->item())): ?>
|
2009-06-16 18:05:23 -07:00
|
|
|
<!-- Use javascript to show the full size as an overlay on the current page -->
|
2009-10-30 00:14:57 -06:00
|
|
|
<script type="text/javascript">
|
2009-06-16 17:57:24 -07:00
|
|
|
$(document).ready(function() {
|
2010-09-04 15:54:07 -07:00
|
|
|
full_dims = [<?= $theme->item()->width ?>, <?= $theme->item()->height ?>];
|
2009-10-04 00:27:22 -06:00
|
|
|
$(".g-fullsize-link").click(function() {
|
2010-09-04 15:54:07 -07:00
|
|
|
$.gallery_show_full_size(<?= html::js_string($theme->item()->file_url()) ?>, full_dims[0], full_dims[1]);
|
2009-06-16 17:57:24 -07:00
|
|
|
return false;
|
|
|
|
|
});
|
2010-09-04 15:54:07 -07:00
|
|
|
|
|
|
|
|
// After the image is rotated or replaced we have to reload the image dimensions
|
|
|
|
|
// so that the full size view isn't distorted.
|
2013-03-11 17:16:20 +01:00
|
|
|
$("#g-photo").on("gallery.change", function() {
|
2010-09-04 15:54:07 -07:00
|
|
|
$.ajax({
|
|
|
|
|
url: "<?= url::site("items/dimensions/" . $theme->item()->id) ?>",
|
|
|
|
|
dataType: "json",
|
|
|
|
|
success: function(data, textStatus) {
|
|
|
|
|
full_dims = data.full;
|
|
|
|
|
}
|
|
|
|
|
});
|
2010-09-09 21:04:18 -07:00
|
|
|
});
|
2009-06-16 17:57:24 -07:00
|
|
|
});
|
|
|
|
|
</script>
|
2009-06-16 17:17:39 -07:00
|
|
|
<? endif ?>
|
|
|
|
|
|
2009-10-04 00:27:22 -06:00
|
|
|
<div id="g-item">
|
2008-12-13 23:02:16 +00:00
|
|
|
<?= $theme->photo_top() ?>
|
2009-01-08 17:13:06 +00:00
|
|
|
|
2009-11-14 16:18:49 -08:00
|
|
|
<?= $theme->paginator() ?>
|
2008-11-21 20:13:28 +00:00
|
|
|
|
2009-10-04 00:27:22 -06:00
|
|
|
<div id="g-photo">
|
2009-03-31 05:14:40 +00:00
|
|
|
<?= $theme->resize_top($item) ?>
|
2009-05-10 20:02:40 +00:00
|
|
|
<? if (access::can("view_full", $item)): ?>
|
2009-10-04 00:27:22 -06:00
|
|
|
<a href="<?= $item->file_url() ?>" class="g-fullsize-link" title="<?= t("View full size")->for_html_attr() ?>">
|
2009-05-10 20:02:40 +00:00
|
|
|
<? endif ?>
|
2010-05-14 16:55:15 -07:00
|
|
|
<?= $item->resize_img(array("id" => "g-item-id-{$item->id}", "class" => "g-resize")) ?>
|
2009-05-10 20:02:40 +00:00
|
|
|
<? if (access::can("view_full", $item)): ?>
|
|
|
|
|
</a>
|
|
|
|
|
<? endif ?>
|
2009-03-31 05:14:40 +00:00
|
|
|
<?= $theme->resize_bottom($item) ?>
|
|
|
|
|
</div>
|
2009-01-01 22:56:57 +00:00
|
|
|
|
2009-10-04 00:27:22 -06:00
|
|
|
<div id="g-info">
|
2009-08-29 22:54:20 -07:00
|
|
|
<h1><?= html::purify($item->title) ?></h1>
|
|
|
|
|
<div><?= nl2br(html::purify($item->description)) ?></div>
|
2009-01-01 22:56:57 +00:00
|
|
|
</div>
|
2008-11-11 20:54:12 +00:00
|
|
|
|
2008-11-22 21:46:34 +00:00
|
|
|
<?= $theme->photo_bottom() ?>
|
2008-11-06 07:20:06 +00:00
|
|
|
</div>
|