Customizing templates - Adding static positions to index
bullyboy1
Joined: 2005-05-19
Posts: 11 |
Posted: Sat, 2005-05-21 18:07 |
I am in the process of customizing the index page to have placement for a featured photo and a featured photo story/album. http://www.heraldextra.com/gallery I have created a new layout and am editing the albumBody.tpl. I have been able to get the desired results by including a php file into the template with {include_php . That php file then contains @readfile method of pulling an image block. My concern is that this is not being cached and I was wondering if there was a way using the {g-> method to pull a specific photo or album and pass it the same paramaters as the @readfile block method. I have tried several variations on the code below with no results:
Any ideas? Am I overlooking a tutorial somewhere on the {g usage? Thanks for your help. |
|
Posts: 8601
perhaps you could use GalleryEmbed::getImageBlock for this?
see modules/core/classes/GalleryEmbed.class
Posts: 11
I tried that as well but it looks like embed.php, where the getImageBlock function resides, restates another function so an error is thrown. I was just hoping to somehow use Smarty to pull the photos.
Posts: 32509
bullyboy1, i guess you still use beta 2 or another old version, because there's no GalleryEmbed class or getImageBlock function in embed.php.
in beta 3, GalleryEmbed was moved from embed.php to modules/core/classes/GalleryEmbed.class.