function PWCartCheckout_wapp(wa_txt) {
cid = (typeof cid !== 'undefined') ? cid : GetAlexCartID();
let stepcode="L'ID del tuo carrello é "+cid+" e contiene:
\n";
stepcode+=wa_txt.replaceAll("\n","
")+"
\n";
stepcode+="Se hai dubbi o domande, puoi porli tramite Whatsapp o e-mail usando i pulsanti qui sotto.
\n";
stepcode+="Ti risponderemo al piú presto sullo stesso canale!
\n";
let watext="Ho delle domande relative al carrello nr. "+cid+" che contiene:\n\n"+wa_txt;
stepcode+="Scrivici via Whatsapp
\n";
stepcode+="Scrivici via E-mail\n";
optbox = jQuery("
", { id: 'optbox', style: 'width:auto;height:auto;', html: stepcode});
optbox.dialog({
title : "Pre-ordine",
draggable: false,
resizable: false,
closeOnEscape: true,
modal : true,
close: function( event, ui ) {jQuery( this ).dialog( "close" ); jQuery('#optbox').remove();},
width: jQuery(window).width()*0.98,
height: (window.innerHeight || document.documentElement.clientHeight || document.body.clientHeight),
position: { my: "center", at: "top", of: window },
create: function( event, ui ) { jQuery(this).parent().css("maxWidth", "980px"); },
buttons: {
"Chiudi": function() {
jQuery( this ).dialog( "close" );
jQuery('#optbox').remove();
}
}
});
}
function PWCartCheckout2(cid) {
cid = (typeof cid !== 'undefined') ? cid : GetAlexCartID();
let carturl="https://alexander-venezia.com/alexcart/cart.php?action=PayCC&cid="+encodeURIComponent(cid)+"&back="+encodeURIComponent(window.top.location.href);
let stepcode="";
stepcode+="\n";
stepcode+="
SPEDIZIONE
\n";
stepcode+="Come vuoi ricevere i tuoi prodotti?
\n";
stepcode+="
Ritiro in punto di ritiro (gratuito)\n";
stepcode+="
Disponibile a:
- Venezia in zona campo San Barnaba
- Lido di Venezia zona Gran Viale
\n";
stepcode+="
Spedizione a domicilio in Italia (+8 euro)\n";
stepcode+="Se invece non sei pronto ad ordinare e/o hai dei dubbi/domande,
";
stepcode+="
Clicca qui per contattarmi
\n";
stepcode+="
\n";
optbox = jQuery("", { id: 'optbox', style: 'width:auto;height:auto;', html: stepcode});
optbox.dialog({
title : "SPEDIZIONE",
draggable: false,
resizable: false,
closeOnEscape: true,
modal : true,
close: function( event, ui ) {jQuery( this ).dialog( "close" ); jQuery('#optbox').remove();},
width: jQuery(window).width()*0.98,
height: (window.innerHeight || document.documentElement.clientHeight || document.body.clientHeight),
position: { my: "center", at: "top", of: window },
create: function( event, ui ) { jQuery(this).parent().css("maxWidth", "980px"); },
buttons: {
"Chiudi": function() {
jQuery( this ).dialog( "close" );
jQuery('#optbox').remove();
}
}
});
}
function PWCartCheckout(cid) {
cid = (typeof cid !== 'undefined') ? cid : GetAlexCartID();
var par="action=checkout";
par+="&cid="+encodeURIComponent(cid);
var params = {
type: "POST",
url: "https://alexander-venezia.com/alexcart/cart.php",
dataType: 'json',
cache: false,
data: par,
success: function(result){
PWCartCheckout_wapp(result.html_checkout)
}
};
jQuery.ajax(params);
}
function PWShowPriceFromAlexCart(code) {
let par="action=AlexCartShowPrice";
par+="&code="+encodeURIComponent(code);
par+="&cid="+encodeURIComponent(GetAlexCartID());
let params = {
type: "POST",
url: "https://alexander-venezia.com/alexcart/cart.php",
data: par,
dataType: 'json',
success: function(result){
optbox = jQuery("", { id: 'optbox', style: 'width:auto;height:auto;', html: result.html});
optbox.dialog({
title : "Quantity Discounts",
draggable: false,
resizable: false,
closeOnEscape: true,
modal : true,
close: function( event, ui ) {jQuery( this ).dialog( "close" ); jQuery('#optbox').remove();},
width: 'auto',
height: 'auto',
position: { my: "center", at: "top", of: window },
create: function( event, ui ) { jQuery(this).parent().css("maxWidth", "980px"); },
buttons: {
"Chiudi": function() {
jQuery( this ).dialog( "close" );
jQuery('#optbox').remove();
}
}
});
}
};
jQuery.ajax(params);
}
function PWShowOptionDesc(pg) {
let html="