hello guys, i have a website shop and i have this code: <script>
paypal.Buttons({
style: {
shape: 'rect',
color: 'blue',
layout: 'vertical',
label: 'pay',
},
createOrder: function(data, actions) {
return actions.order.create({
purchase_units: [{
amount: {
value:",3,"
}
}]
});
},
onApprove: function(data, actions) {
return actions.order.capture().then(function(details) {
alert('Transaction completed by ' +
details.payer.name.given_name + '!');
$.ajax({
url: 'thanks.php',
type:'POST',
data:{ cartItems:2,id:details.payer.payer_id},
}).done(function() {
$('#thankYou').append('<h1 style=text-align:center;>Thank you</h1>');
});
});
}
}).render('#paypal-button-container'); now i dont want to send the payer id with ajax after the paid, i want send my id account how can i do that?
... View more