Support » Plugin: Advanced Order Export For WooCommerce » Add data from YITH Multiple Shipping Addresses

  • Duke



    I would need to add the shipping data (per order item/qty), to the export.
    I’m using the YITH Multiple Shipping Addresses plugin.

    It works in a very similar way as the WooCommerce addon.
    User can choose a different address for each item inside an order, and for each qty of the same item.

    This is what I got this far:

    foreach ( $order->get_shipping_methods() as $item ) {
    	$item_meta_data = $item->get_meta_data();
    	foreach ( $item_meta_data as $meta_data_item ){
    		if($meta_data_item->key == 'ywcmas_shipping_destination') {

    Which gives us:

    array(9) {
      string(2) "IT"
      string(2) "AB"
      string(5) "12345"
      string(7) "City Name"
      string(25) "Some address 123"
      string(0) ""
      string(22) "Some First Name"
      string(25) "Some Last Name"
      string(0) ""

    The company name could also be there (it’s not in this example).

    How do integrate this data, into the export??

    Thank you for your help!!

    • This topic was modified 1 year ago by Duke.
Viewing 6 replies - 1 through 6 (of 6 total)
Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Add data from YITH Multiple Shipping Addresses’ is closed to new replies.