ajax phone
This commit is contained in:
parent
30e5978a47
commit
8333454ed9
|
@ -1,7 +1,7 @@
|
|||
jQuery(document).ready(function () {
|
||||
var host = window.location.hostname;
|
||||
$('#nodename').html(host);
|
||||
|
||||
$('#nodename').html(host);
|
||||
|
||||
$("#formphone").submit(function(e) {
|
||||
e.preventDefault(); // avoid to execute the actual submit of the form.
|
||||
console.log("button PHONE clicked");
|
||||
|
@ -13,28 +13,29 @@ jQuery(document).ready(function () {
|
|||
var parrain = jQuery("#parrain");
|
||||
var naissance = jQuery("#naissance");
|
||||
var data = '';
|
||||
// ajax call to ajax.php
|
||||
// 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("<p>Votre inscription en prise en compte...</p>");
|
||||
});
|
||||
});
|
||||
|
||||
$("#formlink").submit(function(e) {
|
||||
|
||||
$("#formlink").submit(function(e) {
|
||||
e.preventDefault(); // avoid to execute the actual submit of the form.
|
||||
console.log("button LINK clicked");
|
||||
$("#linkresultat").html("<p><h3>Astroport vous remercie pour votre nourriture médiatique</h3></p>");
|
||||
$("#linkresultat").html("<p><h3>Merci! nous envoyons votre message à la GUILDE</h3></p>");
|
||||
// declare these vars
|
||||
var link = jQuery("#link");
|
||||
var phone = jQuery("#phone");
|
||||
var data = '';
|
||||
// ajax call to ajax.php
|
||||
jQuery.getJSON("ajax.php", {
|
||||
link: link.val()
|
||||
link: link.val(), phone: phone.val()
|
||||
}, function (data) {
|
||||
$("#linkresultat").html("<p><h3>Astroport vous remercie pour votre nourriture médiatique</h3></p>");
|
||||
$("#linkresultat").html("<p><h3>Astroport vous remercie pour votre nourriture médiatique</h3></p>");
|
||||
});
|
||||
});
|
||||
|
||||
|
||||
|
||||
});
|
||||
|
|
Loading…
Reference in New Issue