$(function($) {
    $('a.title').cluetip({splitTitle: '|'});
    $('a.appointment').cluetip({local: true, showTitle: false});
       
    $("a[rel^='lightbox']").slimbox({loop: true, counterText: jsTranslation[0]}, function(el) {
        return [
            $(el).find('img').attr('src').replace(/_(medium|dfclasses_gallery_full|big|small|large)\.(\w+)$/, '_dfclasses_gallery_lightbox.$2'), 
            $(el).find('img').attr('alt')
        ];
    }, function(el) {
        return (this == el) || ((this.rel.length > 8) && (this.rel == el.rel));
    });
    
    $("div.preview > div > a[rel^='lightbox']").unbind('click');
    $("div.preview-last > div > a[rel^='lightbox']").unbind('click');
});