I would like to administer this feature in my Joomla bridged gallery.
However in reading the code changes, I have a different issue.
First off, I have Nibbler's YouTube mod integrated into this section of the code:
if ($mime_content['content']=='image') {
if (preg_match('/^youtube_(.*)\.jpg$/', $CURRENT_PIC_DATA['filename'], $ytmatches)){
$vid = $ytmatches[1];
$pic_html = '<object width="425" height="350"><param name="movie" value="http://www.youtube.com/v/'. $vid . '&fs=1"></param><param name="allowFullScreen" value="true"></param><embed src="http://www.youtube.com/v/'. $vid . '&fs=1&rel=0&color1=0xcc2550&color2=0xe87a9f" type="application/x-shockwave-flash" allowfullscreen="true" width="425" height="350"></embed></object><br />';
} elseif (isset($image_size['reduced'])) {
$winsizeX = $CURRENT_PIC_DATA['pwidth']+5; //the +'s are the mysterious FF and IE paddings
$winsizeY = $CURRENT_PIC_DATA['pheight']+3; //the +'s are the mysterious FF and IE paddings
$pic_html = "<a href=\"javascript:;\" onclick=\"MM_openBrWindow('displayimage.php?pid=$pid&fullsize=1','" . uniqid(rand()) . "','scrollbars=yes,toolbar=no,status=no,resizable=yes,width=$winsizeX,height=$winsizeY')\">";
$pic_title = $lang_display_image_php['view_fs'] . "\n==============\n" . $pic_title;
$pic_html .= "<img src=\"" . $picture_url . "\" class=\"image\" border=\"0\" alt=\"{$lang_display_image_php['view_fs']}\" /><br />";
$pic_html .= "</a>\n";
} else {
$pic_html = "<img src=\"" . $picture_url . "\" {$image_size['geom']} class=\"image\" border=\"0\" alt=\"\" /><br />\n";
}
If I am interpreting correctly, I would only change the link to refer to the lightbox
From:
$pic_html = "<a href=\"javascript:;\" onclick=\"MM_openBrWindow('displayimage.php?pid=$pid&fullsize=1','" . uniqid(rand()) . "','scrollbars=yes,toolbar=no,status=no,resizable=yes,width=$winsizeX,height=$winsizeY')\">";
$pic_title = $lang_display_image_php['view_fs'] . "\n==============\n" . $pic_title;
$pic_html .= "<img src=\"" . $picture_url . "\" class=\"image\" border=\"0\" alt=\"{$lang_display_image_php['view_fs']}\" /><br />";
$pic_html .= "</a>\n";
To:
$pic_html = "<a href=\"$picfull_url\" rel=\"lightbox\" title=\"$pic_title\">";
$pic_html .= "<img src=\"" . $picture_url . "\" class=\"image\" border=\"0\" alt=\"{$lang_display_image_php['view_fs']}\" /><br />";
$pic_html .= "</a>\n";
Then obviously add the lightbox scripts and add the references in the <head> as described earlier
Is that correct?
Also, I am using a similar script (HighSlide see
http://vikjavev.no/highslide/) elsewhere on the site (This is used by a Joomla plugin that converts lightbox tags to HighSlide). Could I use this instead, or would it be easier to K.I.S.S. and stick with Lightbox?