Support » Plugin: WooCommerce » Shipping and/or Billing Address not being sent to PayPal

  • Resolved mintjelly

    (@mintjelly)


    I see that this issue has been marked as resolved elsewhere in this forum, but it is not resolved for me. The response from Paypal as of 23 August 2019 is as follows:

    “Please contact Woocommerce and ask them to modify a code parameter ‘no_shipping’ from existing value ‘1’ into ‘2’ so that customers’ shipping address for your future transactions will be showing there.”

    Please advise how this can be done as soon as possible. This is a live shop and the website owner is stressed.

    The page I need help with: [log in to see the link]

Viewing 4 replies - 1 through 4 (of 4 total)
  • mintjelly

    (@mintjelly)

    Does anyone actually respond to these questions, or is Woocommerce under-supported?

    Plugin Support m155y5

    (@m155y5)

    Automattic Happiness Engineer

    Hi @mintjelly

    Can you please clarify whether you’re using PayPal Standard or the PayPal Checkout Gateway plugin?

    PayPal Standard.

    Plugin Support Jesse Pearson

    (@jessepearson)

    Automattic Happiness Engineer

    @mintjelly The change you want can be done with the below filter. This would need to be added to your functions.php of your child theme or through a code snippet plugin.

    
    /**
     * Simple filter to change the 'no_shipping' value from 1 to 2 with 
     * PayPal Standard in WooCommerce when no shipping is needed.
     * 
     * @param  arr $data The original data.
     * @return arr       The updated data.
     * @link   https://wordpress.org/support/topic/shipping-and-or-billing-address-not-being-sent-to-paypal-2/
     * @link   https://gist.github.com/jessepearson/3c258df272e73db875e901c0909a3554
     */
    function jp_set_paypal_no_shipping_to_two( $data ) {
    
    	if ( isset( $data['no_shipping'] ) && 1 == $data['no_shipping'] ) {
    		$data['no_shipping'] = 2;
    	}
    	return $data;
    }
    add_filter( 'woocommerce_paypal_args', 'jp_set_paypal_no_shipping_to_two', 10 );
    

    Also found here:
    https://gist.github.com/jessepearson/3c258df272e73db875e901c0909a3554

Viewing 4 replies - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.