function addScript(src,callback) { var s = document.createElement('script'); s.setAttribute('src', src); s.onload=callback; document.body.appendChild(s); } function callback_main() { window.setTimeout(function(){ if ( typeof UniteGalleryMain == 'function' ) { $('div[id^="gallery"]').each(function(){ $(this).unitegallery({ gallery_images_preload_type:"minimal", gallery_autoplay:false, slider_control_zoom:true, gallery_play_interval: 10000, slider_scale_mode: "fit", slider_scale_mode_fullscreen: "fit", slider_enable_bullets: false, gallery_autoplay:true, tiles_type:"justified", gallery_theme:"tiles"}); $('.ug-strip-panel').css({'background':'transparent'}); $('.ug-default-button-fullscreen-single, .ug-default-button-play-single, .ug-lightbox-button-close').css({'-webkit-filter':'invert(100%)'}); $('.ug-lightbox').css({'background':'rgba(255,255,255,0.55)'}); }); } }, 1000); } function callback2_flickrembed_50() { $('head').append(''); $('head').append(''); $('#flickrembed_50').html('
'); addScript('https://flickrembed.com/unitegallery/themes/tiles/ug-theme-tiles.js', callback_main); } function callback1_flickrembed_50() { $.getScript("https://flickrembed.com/js/remodal.min.js"); addScript('https://flickrembed.com/unitegallery/js/unitegallery.min.js', callback2_flickrembed_50); } addScript('https://code.jquery.com/jquery-1.12.1.min.js', callback1_flickrembed_50);