DirGallery Extension Docs version 0.7

This extension enables you to add automatic simple galleries to your entries or pages from images in filesystem directory. Derived from gallery extension.


dirgallery snippet

A example of automatic page gallery from subdirdir with same name as uri of page in dir images/gallery:

  [[dirgallery dir="gallery/$uri" popup="thickbox" header="<div class="gallery">" footer="</div>"]]
    <a href='%imageurl%%filename%' class="thickbox" title="%title%" rel="gallery-%uid%" >
    <img src="%pivotxurl%includes/timthumb.php?src=%filename%&amp;w=106&amp;h=80&amp;zc=1" alt="%alttext%" />

The snippet takes optional parameters:

You can style the output in your CSS. A very basic example would be:

  div.gallery { margin: 0; padding: 0; }
  div.gallery img { margin: 2px; padding: 0; }

If you have enabled the fancybox extension and want to use it instead, replace the two "thickbox" strings with "fancybox" in the example above.

example with czech iptc title from picasa, image legend and fancybox

[[dirgallery dir="gallery/$uri" popup="fancybox" header="<div class="gallery">" footer="</div>" iptcindex="2#120" iptcencoding="Windows-1250" ]]
    <div class="gallery-item">
        <a href='%imageurl%%filename%' class="fancybox" title="%title%" rel="gallery-%uid%" >
            <div class="gallery-img"><img src="%pivotxurl%includes/timthumb.php?src=%filename%&amp;w=150&amp;h=112&amp;zc=1" alt="%alttext%" /></div>
            <div class="gallery-title">%title%</div>
div.gallery {
    margin: 0px;
    padding: 0px;
div.gallery img {
    margin: 0px;
    padding: 0px;
div.gallery div.gallery-item {
    float: left;
    margin: 5px;
div.gallery div.gallery-item a {
    color: #000;
    text-decoration: none;