paypal.Buttons dont allow shipping address change

Greg1245
Contributor
Contributor

Hello,

After some time I cannot find what I am looking for.

I would like to disable the change shipping address in the paypal.Buttons Checkout.

 

I found on the net that you are supposed to use NOSHIPPING=1 to disable checkout from show the change address field.

 

I have this code:

<script src="https://www.paypal.com/sdk/js?client-id=sb&currency=USD"></script>
<div id="paypal-button-container" style=" width: 160px; height: 30px"></div>
<script>
paypal.Buttons({
style: {
NOSHIPPING: 1,
layout: 'horizontal',
tagline: false,
shape: 'pill',
size: 'responsive',
label: 'pay',
},

// Set up the transaction
createOrder: function (data, actions) {
return actions.order.create({
purchase_units: [{
amount: {
value: '<%=FormatNumber(Gtotal,2)%>'
}
}]
});
},
// Finalize the transaction
onApprove: function (data, actions) {
return actions.order.capture().then(function (details) {

alert(details.status);
error: function (data) {
alert("error");
},
success: function (data) {
alert("happyhappyjoyjoy");
}
});
});
},
onCancel: function (data) {
alert("boohoo");
}
}).render('#paypal-button-container');
</script>

 

 

But the paypal process still shows the shipping option.

 

So what do I need to do to correct this or is the change of address I should process into my process?

 

Thanks ahead of time.

 

Login to Me Too
2 REPLIES 2

LAFRENCHI
Member
Member

Have you found the solution ?

I would like to disable the shipping address choice.

Login to Me Too

RoccoDen
Contributor
Contributor

I have the same problem.. has anyone find a solution ??

Login to Me Too

Haven't Found your Answer?

It happens. Hit the "Login to Ask the community" button to create a question for the PayPal community.