Templates

The plugin is displayed using a template system very similar to nucleus skins and templates.

The first step in the display is when the plugin calls the nucleus NPGallery skin. This provides the general look, ie banner, side menus, footers, whatever. The <%gallery(link)%> tag in the NPGallery skin is where the gallery page (list, album or picture) is displayed. To display the requested gallery page the appropriate gallery template is used. These templates are freely editable in the gallery admin area and are a powerful way to control how gallery is displayed

In general, each template has a header, body and footer segment. With pages with repeated information such as thumbnails in an album, the header is displayed, followed by repitions of the body, then the footer. For example if we call the header H, the body B and footer F, an album page would be contructed H B B (repeated) B B F. Following is list of template tags and the information they represent

Gallery List: Displayed by <%gallery(link)%> and by clicking on Gallery in the breadcrumb
Tag Description Section
breadcrumb Displays Breadcrumb navigation (in gallery list only the word Gallery) All
sortbytitle Generates a link to display gallery list sorted by album title, ie <a href="<%sortbytitle%>"> Header
sortbydescription Generates a link to display gallery list sorted by album description. Header
sortbyowner Generates a link to display gallery list sorted by album owner. Header
sortbymodified Generates a link to display gallery list sorted by date last modified. Header
sortbynumber Generates a link to display gallery list sorted by number of images in album. Header
albumlink link to album Body
albumthumbnail absolute reference to the album thumbnail (assignable in admin area|gallery|configuration). Usage: <img src="<%albumthumbnail%>" /> Body
centeredtopmargin(height,adjustment) CSS inline style used to vertically align thumbnail (if using albumthumbnail). Height is the height of the thumbnail container, adjustment is a number: a negative value to shift the thumbnail up, positive to shift down. Used to make space for text under thumbnail. Usage: Body
title Body
description Body
ownerid Body
ownername Body
modified Body
numberofimages Body
addalbumlink H/F
addpictureslink H/F
if(canaddpicture) All
if(canaddalbum) All

Album: Displayed by clicking on album link in gallery list
Tag Description Section
breadcrumb(sep) Displays Breadcrumb navigation with the specified seperator, default is >. For example to change the breadcrumb to Gallery -> Album change the tag to <%breadcrumb(->)%> All
albumtitle
albumdescription
picturedescription
picturelink
thumbnail
centeredtopmargin
pictureviews
editalbumlink
addpicturelink
picturetitle
pages
albumlink
if(canaddpicture)
if(caneditalbum)

Picture: Displayed by clicking on thumbnail in album
Tag Description Section
breadcrumb(sep) Displays Breadcrumb navigation with the specified seperator, default is >. For example to change the breadcrumb to Gallery -> Album change the tag to <%breadcrumb(->)%> All
albumlink
albumtitle
description
fullsizelink
intermediatepicture
title
height
width
owner
date
editpicturelink
deletepicturelink
nextlink
previouslink
comments
commentform
if(caneditpicture)
if(commentsallowed)
if(next)
if(prev)

 


Comments
Tag Description Section

Promo post template
Tag Description Section

Version History