func_combine_script(array('id'=>'jquery.colorbox', 'path'=>'plugins/lightbox/js/jquery.colorbox.js'));
$template->func_combine_script(array('id'=>'core.scripts', 'path'=>'themes/default/js/scripts.js'));
$template->func_combine_css(array('path'=>'plugins/lightbox/theme/'.$params['theme'].'/colorbox.css'));
$template->block_html_head('','
');
foreach($tpl_thumbnails_var as $key => $tpl_var)
{
// Image URL for lightbox
if ($newurl = get_lightbox_url($pictures[$key]))
{
$tpl_thumbnails_var[$key]['URL'] .= '" id="img-'.$pictures[$key]['id'].'" name="'.$newurl;
}
else
{
continue;
}
// Title display
if ($params['display_name'])
{
$tpl_thumbnails_var[$key]['URL'] .= '" title="'.get_lightbox_title($pictures[$key], $params['name_link']);
}
// Arrows display
if ($params['display_arrows'])
{
$tpl_thumbnails_var[$key]['URL'] .= '" rel="colorbox'.$conf['lightbox_rel'];
}
}
// Add all items from category
if ($params['display_arrows'] and $params['all_cat'] and !empty($page['navigation_bar']))
{
$rank_of = array_flip($page['items']);
if ($page['start'] > 0)
{
$selection = array_slice($page['items'], 0, $page['start']);
$template->concat('PLUGIN_INDEX_CONTENT_BEGIN', get_lightbox_extra_pictures($selection, $rank_of, $params['name_link']));
}
if (count($page['items']) > $page['start'] + $page['nb_image_page'])
{
$selection = array_slice($page['items'], $page['start'] + $page['nb_image_page']);
$template->concat('PLUGIN_INDEX_CONTENT_END', get_lightbox_extra_pictures($selection, $rank_of, $params['name_link']));
}
}
?>