A theme is the outermost skin of Gallery. It's a thin but powerful layer that allows you to control almost every aspect of the user interface to make Gallery look exactly the way that you want. Gallery provides several themes to choose from and there are several user-contributed themes available to download and install. Gallery Administrators can choose which themes are available and set different themes for individual albums.
There are several ways to customize how your Gallery looks. The first way is to select features to display in an installed theme in Gallery’s site administration area. Another way that to customize Gallery is to edit a theme’s template and style sheet files. The final way is to create your own theme—based on an existing theme or from scratch.
Select and Configure:
- Theme Catalog – A list of Gallery 2 standard and user-contributed themes, color packs, and icon packs.
- Managing and Configuring Themes – Information about installing, activating, upgrading, and configuring themes to change your Gallery’s appearance.
Edit or Create a new one:
- How Tos – A collection of step-by-step procedures to show you how to customize the look of your Gallery.
- Editing and Creating Themes – An overview of Gallery 2’s theme system with detailed documentation showing how to edit and create theme templates and style sheets.
Embed it:
Gallery 2 Templating System
Gallery's templating system is based on Smarty, a generic PHP templating system which uses separate template files to lay pages out. Gallery 2 customises this with several extra objects and variables. The following pages describe the templating system in more detail:
- Smarty - the template engine that assembles user- and Gallery-supplied content into the pages that are presented to the user
- Modifiers - modifiers can alter the way that Smarty presents text. Gallery 2 extends the built-in ones with several that relate to display text in a gallery
- Tags - Gallery 2 extends smarty with its own tags (e.g. {g->url ...}) to provide useful shortcuts related to Gallery functions
- Blocks - in the same way that blocks can be manipulated using the Site Admin interface in Gallery 2, they can also be used within a template by using the g->block function
- Callbacks - callbacks are used to load data into blocks within templates using the g->callback function
- Variables - Gallery 2 makes several variables accessible to a template which provide information about the current image, album, user and environment