jQuery(document).ready(function(){
jQuery("#phModalPlay").on("hidden.bs.modal", function (e) {
jQuery("#phModalPlay iframe").attr("src", jQuery("#phModalPlay iframe").attr("src"));
jQuery("audio").each(function(){this.pause();this.currentTime = 0;});
jQuery("video").each(function(){this.pause();this.currentTime = 0;});
});
jQuery(".pd-modal-button").on("click", function () {
var $target = jQuery(this).data("target");
var $href = jQuery(this).data("href");
var $body = $target + "Body";
var $dialog = $target + "Dialog";
var $height = jQuery(this).data("height");
var $width = jQuery(this).data("width");
var $heightD= jQuery(this).data("height-dialog");
var $widthD = jQuery(this).data("width-dialog");
var $type = jQuery(this).data("type");
jQuery($body).css("height", $height);
jQuery($target).css("width", $width);
jQuery($body).css("overflow-y", "auto");
jQuery($dialog).css("height", $heightD);
jQuery($dialog).css("width", $widthD);
if ($type == "image") {
jQuery($body).html('
');
} else if ($type == "document") {
$widthD = $widthD -50;
$heightD = $heightD -40;
jQuery($body).html('
');
} else {
jQuery($body).load($href, function (response, status, xhr) {
if (status == "success") {
/*jQuery($target).modal({ show: true });*/
}
});
}
});
});
jQuery(function($) {
SqueezeBox.initialize({});
SqueezeBox.assign($('a.pd-modal-button').get(), {
parse: 'rel'
});
});
window.jModalClose = function () {
SqueezeBox.close();
};
// Add extra modal close functionality for tinyMCE-based editors
document.onreadystatechange = function () {
if (document.readyState == 'interactive' && typeof tinyMCE != 'undefined' && tinyMCE)
{
if (typeof window.jModalClose_no_tinyMCE === 'undefined')
{
window.jModalClose_no_tinyMCE = typeof(jModalClose) == 'function' ? jModalClose : false;
jModalClose = function () {
if (window.jModalClose_no_tinyMCE) window.jModalClose_no_tinyMCE.apply(this, arguments);
tinyMCE.activeEditor.windowManager.close();
};
}
if (typeof window.SqueezeBoxClose_no_tinyMCE === 'undefined')
{
if (typeof(SqueezeBox) == 'undefined') SqueezeBox = {};
window.SqueezeBoxClose_no_tinyMCE = typeof(SqueezeBox.close) == 'function' ? SqueezeBox.close : false;
SqueezeBox.close = function () {
if (window.SqueezeBoxClose_no_tinyMCE) window.SqueezeBoxClose_no_tinyMCE.apply(this, arguments);
tinyMCE.activeEditor.windowManager.close();
};
}
}
};
JCEMediaBox.init({popup:{width:"",height:"",legacy:0,lightbox:0,shadowbox:0,resize:1,icons:1,overlay:1,overlayopacity:0.8,overlaycolor:"#000000",fadespeed:500,scalespeed:500,hideobjects:0,scrolling:"fixed",close:2,labels:{'close':'Chiudi','next':'Successivo','previous':'Precedente','cancel':'Annulla','numbers':'{$current} di {$total}'},cookie_expiry:"",google_viewer:0},tooltip:{className:"tooltip",opacity:0.8,speed:150,position:"br",offsets:{x: 16, y: 16}},base:"/",imgpath:"plugins/system/jcemediabox/img",theme:"standard",themecustom:"",themepath:"plugins/system/jcemediabox/themes",mediafallback:0,mediaselector:"audio,video"});
if(typeof acymailingModule == 'undefined'){
var acymailingModule = [];
}
acymailingModule['emailRegex'] = /^[a-z0-9!#$%&\'*+\/=?^_`{|}~-]+(?:\.[a-z0-9!#$%&\'*+\/=?^_`{|}~-]+)*\@([a-z0-9-]+\.)+[a-z0-9]{2,10}$/i;
acymailingModule['NAMECAPTION'] = 'Nome';
acymailingModule['NAME_MISSING'] = 'Inserisci il tuo nome.';
acymailingModule['EMAILCAPTION'] = 'Email';
acymailingModule['VALID_EMAIL'] = 'Inserisci un indirizzo email valido.';
acymailingModule['ACCEPT_TERMS'] = 'Leggi le note sulla Privacy e sui Termini di Utilizzo';
acymailingModule['CAPTCHA_MISSING'] = 'Inserisci il codice di sicurezza visualizzato nell\'immagine';
acymailingModule['NO_LIST_SELECTED'] = 'Si prega di selezionare le liste a cui si desidera iscriversi';
acymailingModule['level'] = 'enterprise';
acymailingModule['reqFieldsformAcymailing95211'] = Array('name','html');
acymailingModule['validFieldsformAcymailing95211'] = Array('Inserisci un valore per il campo Nome','Inserisci un valore per il campo Ricezione');
acymailing['excludeValuesformAcymailing95211'] = Array();
acymailing['excludeValuesformAcymailing95211']['name'] = 'Nome';
acymailing['excludeValuesformAcymailing95211']['email'] = 'Email';
jQuery(function($){ initTooltips(); $("body").on("subform-row-add", initTooltips); function initTooltips (event, container) { container = container || document;$(container).find(".hasTooltip").tooltip({"html": true,"container": "body"});} });
/*
$( document ).ready(function() {
function SetCookie(cname, cvalue, exdays) {
var d = new Date();
d.setTime(d.getTime() + (exdays*24*60*60*1000));
var expires = "expires="+d.toUTCString();
document.cookie = cname + "=" + cvalue + "; " + expires + "; path=/";
console.log(document.cookie);
}
function GetCookie(cname) {
var name = cname + "=";
var ca = document.cookie.split(';');
for(var i=0; i