img widths
This commit is contained in:
parent
1b804c0189
commit
6fce1d3c3d
|
@ -68,8 +68,8 @@ $('.thumbsDetails').live("click", function(e) {
|
||||||
var bigImage = $(this).attr("data-bigimage");
|
var bigImage = $(this).attr("data-bigimage");
|
||||||
var $img = $('<img />').attr("src", bigImage).addClass("lightboxImg");
|
var $img = $('<img />').attr("src", bigImage).addClass("lightboxImg");
|
||||||
$img.appendTo($cont);
|
$img.appendTo($cont);
|
||||||
var imgWidth = $img.width();
|
var imgWidth = parseInt($img.attr("data-width"));
|
||||||
var imgHeight = $img.height();
|
var imgHeight = parseInt($img.attr("data-height"));
|
||||||
var lightboxWidth = imgWidth + 40;
|
var lightboxWidth = imgWidth + 40;
|
||||||
var lightboxHeight = imgHeight + 60;
|
var lightboxHeight = imgHeight + 60;
|
||||||
$('#lightboxPanel').width(lightboxWidth);
|
$('#lightboxPanel').width(lightboxWidth);
|
||||||
|
|
|
@ -111,7 +111,7 @@
|
||||||
{% for i in imagegallery %}
|
{% for i in imagegallery %}
|
||||||
{% thumbnail i.file "600x500" crop="center" as big %}
|
{% thumbnail i.file "600x500" crop="center" as big %}
|
||||||
{% thumbnail i.file "164x114" crop="center" as thumb %}
|
{% thumbnail i.file "164x114" crop="center" as thumb %}
|
||||||
<img title="{{ i.title }}" src="{{ thumb.url }}" class="thumbsDetails" data-bigimage="{{ big.url }}" />
|
<img title="{{ i.title }}" src="{{ thumb.url }}" width="164" height="114" data-width="{{ big.width }}" data-height="{{ big.height }}" class="thumbsDetails" data-bigimage="{{ big.url }}" />
|
||||||
|
|
||||||
<!--
|
<!--
|
||||||
<a href="{{ big.url }}" title="{{i.title}}" class="thickbox" rel="gall">
|
<a href="{{ big.url }}" title="{{i.title}}" class="thickbox" rel="gall">
|
||||||
|
|
Loading…
Reference in New Issue
Block a user