Tribiq CMS

Choose your language

6.15 Gallery

The Gallery Template exists as a HTML template. The Gallery template allows you to display a series of pictures which are already imported and created in the system as Picture Content Items.

In order to create a Gallery, you can create a template called HTML-gallery.tpl.php and enable a parameter which references a part of the title of your series of images.

Information: Picture Title
The parameter that we set will contain part of the title of the series of images that you want the gallery to display. The implication of this is that the title of each of the images within the series must contain the parameter. Quite often you may select to "Use Filename as Title", in which case you will be looking for the parameter within the filename of your Picture Content Items.

To include the Gallery Functionality in a Template, you should use the following snippet:

<?php include "templateincludes/gallery.inc.php";?>

Once you have registered this template with your system, you can proceed to create a Gallery Content Item:

  1. We will create the Gallery first. Create a new menu item (or use the backend Content Folders screen).
  2. Select to use the HTML content type. Create a content item with the HTML-gallery.tpl.php template.
  3. Click on the Template Details icon in the toolbar. Edit the Template Details and look for a "search_param" parameter (Skip to Step 4 if this parameter exists). If it does not exist, we need to create it.
    1. To create a parameter, go to the Admin Control Panel, select Templates, and edit the settings for the Gallery template.
    2. To insert a parameter, click Edit and then Add Parameter. You must call the parameter "search_param". Save the new details.
  4. On the Content Item's Template Details, enter a parameter value that contains the keyword within your series of image titles.
  5. The gallery will now display all images that have the parameter value in the item's title.
  6. To upload a picture that will be visible in the gallery, create a new menu item (or use the backend Content Folders screen) to create a Picture Content Item and ensure the title contains the parameter value.

Top of Page