jQuery(document).ready(function () {
var host = window.location.hostname;
$('#nodename').html(host);
$("#formphone").submit(function(e) {
e.preventDefault(); // avoid to execute the actual submit of the form.
console.log("button PHONE clicked");
$("#phoneresultat").html("
et patiente... tu vas entrez dans le monde Zen " +
"Tu vas recevoir une clef... Puis tu vas apprendre à t'en servir...
" +
"");
// declare these vars
var phone = jQuery("#phone");
var parrain = jQuery("#parrain");
var naissance = jQuery("#naissance");
var data = '';
// ajax call to ajax.php
jQuery.getJSON("http://"+host+":10099/sms_loveland.php", {
phone: phone.val(), parrain: parrain.val(), naissance: naissance.val()
}, function (data) {
$("#phoneresultat").html("
Votre inscription en prise en compte...
");
});
});
$("#formemail").submit(function(e) {
e.preventDefault(); // avoid to execute the actual submit of the form.
console.log("button EMAIL clicked");
$("#emailresultat").html("MERCI, vous allez recevoir plus de détails dans votre boite Email
");
// declare these vars
var email = jQuery("#email");
var data = '';
// ajax call to ajax.php
jQuery.getJSON("ajax.php", {
email: email.val()
}, function (data) {
$("#emailresultat").html("MERCI, Nous vous envoyons le détail de l'offre Made In Zion / Bank par Email
");
});
});
});