{init_images}
Tag {init_images} is used for displaying images in Saurus4 gallery that is based on filesystem files instead of database records in v3. Since version 4.0.7.
Parameters
- parent - album ID where to get the images. If parent is not defined then current page ID is used.
- name - variable name where the returned data is saved. Default value is "images".
- start - the starting row number to return.
- limit - the number of rows to return. You must use this parameter always with "start" parameter.
- where - additional filtering criteria using WHERE SQL syntax.
Attributes
- id - ID number of the image
- parent_id - ID number of parent object
- title - title of the image
- buttons - action-buttons, available only for editors
- size - size of the displayed image in bytes
- actual_image_size - size of the original image in bytes
- filename - filename of the image
- thumb_path - relative path to the thumbnail image
- thumb_height - height of the thumbnail image in pixels
- thumb_width - width of the thumbnail image in pixels
- image_path - relative path to the image
- image_height - height of the image in pixels
- image_width - width of the image in pixels
- actual_image_path - relative path to the original image
- actual_image_height - height of the original image in pixels
- actual_image_width - width of the original image in pixels
General tags
- <name>_newbutton - allows to add new images to the albums selected folder. 4.5.3
- <name>_first_image - relative path to the first image in the album
- <name>_last_image - relative path to the first image in the album
- <name>_count - the number of returned objects 4.2.1
- <name>_counttotal - the total number of objects found, not affected by "limit" parameter. 4.2.1
- <name>_title - title of the album
Note: Images are ordered by the filenames.
Example
{init_images name="images" parent=$id}
{foreach from=$images item="image"}
<img src="{$image->thumb_path}" alt="{$image->title}" width="{$image->thumb_width}" height="{$image->thumb_height}">
{/foreach}
