Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
Pages: 1
#1 2008-08-30 16:49:34
- daikw
- Member
- Registered: 2007-10-06
- Posts: 39
Fixing the layout of a gallery.
Hello,
I have a nice image gallery in progress , which has been made possible through the help of “Bloke”.
I would like to adjust the layout so that the thumbnails always appear in the same grid – always 3 across, by X down.
The fullsize images to the right change width a lot, and when they do, the thumbnails change from lining up; 3, 4, or even 5 across.
The reason being; there is one div containing the whole gallery (which is of a fixed width) and another div containing the fullsize images. The thumbnails then fill up the remaining space.
One idea I had is to put the thumbnail rack into another div, and fix the size of that also. Unfortunately I do not know how to do this without effecting the code that Bloke has very kindly written. There may also be other suggestions from people who have experience working with galleries!
If anyone can show me the way, I would be most grateful. :)
Thanks,
Dai
P.S. if I have left out anything of importance here, please tell me.
Forms
photo_page
<div id="gallery">
<txp:smd_gallery category="?title">
<txp:smd_if field="{counter}" operator="eq" value="1">
<div id="fullsize">
<txp:image id="{id}" />
<span id="caption">{title}</span>
</div>
</txp:smd_if>
<a href="{url}" class="thumb" title="{caption}"
onclick="document.getElementById('fullsize').img.src = this.href;
document.getElementById('caption').value = this.title;
return false;">
<txp:thumbnail id="{id}" />
</a>
</txp:smd_gallery>
</div>
gallery_layout
{changed:category_title}
<a rel="lightbox" href="{url}" title="{title}">{object}</a>
Last edited by daikw (2008-08-30 16:52:07)
Offline
Pages: 1