1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/spip_ynh.git synced 2024-09-03 20:25:59 +02:00
spip_ynh/sources/plugins-dist/mediabox/javascript/splash.mediabox.js
2015-04-28 17:10:23 +02:00

20 lines
No EOL
510 B
JavaScript

(function($){
$(function(){
// poser le cookie au callback de la box chargee
var set_cookie = function() {
$.cookie("modalsplash", box_settings.splash_url, { expires: 7 });
}
$.modalboxsplash = function(href, options) {
$.fn.mediabox($.extend({
href:href,
onComplete:set_cookie,
overlayClose:true
},options));
};
// ouvrir la splash page si pas deja vue
if ($.cookie("modalsplash") != box_settings.splash_url)
$.modalboxsplash(box_settings.splash_url);
});
})(jQuery);