Hi,
I have read the dynamic albums guide but when i use
`<?php<br />
zp_load_album('all.alb');
prepareAlbumPage();
?>`
i get this error:
`Warning: Cannot modify header information - headers already sent by (output started at /home/adetaran/public_html/dev/themes/zpbase/index.php:18) in /home/adetaran/public_html/dev/zp-core/functions-common.php on line 501`
I dont really want to go messing with anything in the core files so could anyone help shed some light on how i would get this dynamic album to show on the home page. Im using the dynamic album as a way to show all images on the homepage.
I am using the zbBase theme and putting the code in the codeblock of the gallery.
Thanks,
Alex
Comments
Since codeblocks go through a function call they are a bit different and the global context needed may generally not be setup correctly that easily.
Editing the theme might be a way. Or maybe it has an option for a custom page. Then you could create a new theme page for the multiple_layouts plugin and use that for the homepage.
http://www.zenphoto.org/news/zenphotos-object-model-framework
This will get you started... place in codeblock as you say (make sure codeblock is called in theme):
`
<?php </p>
$album = newAlbum('all.alb');
$images = $album->getImages();
foreach ($images as $image) {
$image = newImage($album,$image);
echo '
echo 'getThumb())).'" alt="'.html_encode($image->getTitle()).'" />';
echo '
'.$image->getTitle().'
';echo '
}
?>
`
note there will be no pagination!