WordPress.org

Ready to get started?Download WordPress

Forums

WooCommerce - excelling eCommerce
Changing Shipping Adress via Code (1 post)

  1. Andi
    Member
    Posted 1 year ago #

    Hi Gents,
    i wanna change the shipping adress via code.

    When a customer has chosen the shipping method "selfpickup" it's necessary to switch the shipping adresse to my own adress, 'cause of the taxes and so on. Espacially for customers from foreign countries.

    In the template "sceond-checkout.php" I've changed the data in the $_SESSION['first_checkout_post_array'], $woocommerce->customer->set_shipping_country($myCountry) and update_user_meta($user_id, 'shipping_country', $myCountry);.

    On the viewing forms, everything is fine, but the orderdata that are in the database contains just the old shipping adresse, also the email that is send to the customer.

    Any hints how i can change this behaviour?

    BR Andi

    http://wordpress.org/extend/plugins/woocommerce/

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic

Tags

No tags yet.