In the old version of Fancybox, I was able to find a code that would allow me custom titles for individual images. But upgrading to Fancybox v.2, I can't figure out how to update the function so it will still work. Yes, I'm a newbie. Help, or a link, would be greatly appreciated.
Old code...
<script type="text/javascript">
$(document).ready(function() {
$("a[rel=blanchard_group]").fancybox({
'transitionIn' : 'fade',
'transitionOut' : 'fade',
'titlePosition' : 'over',
'titleShow' : 'true',
'overlayShow' : 'true',
'overlayColor' : '#fff',
'overlayOpacity' : '0.9',
'showNavArrows' : 'true',
'enableEscapeButton' : 'true',
'scrolling' : 'no',
'onStart':function(currentArray,currentIndex,currentOpts){
var obj = currentArray[ currentIndex ];
if ($(obj).next().length)
this.title = $(obj).next().html();},
'titleFormat' : function(title, currentArray, currentIndex, currentOpts) {
return '<span id="fancybox-title-over">' + title + '</span>';
}
});
});
</script>
New code ...
<script type="text/javascript">
$(document).ready(function() {
$(".fancyproject").fancybox({
prevEffect : 'fade',
nextEffect : 'fade',
nextClick : true,
helpers : {
title : {
type : 'inside'
},
overlay : {
opacity : 0.9,
css : {
'background-color' : '#fff'
}
},
thumbs : {
width : 50,
height : 50
}
}
});
});
</script>