Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- add_filter('angelleye_paypal_plus_shipping_line1', 'th_angelleye_paypal_plus_shipping_line1', 10, 2);
- function th_angelleye_paypal_plus_shipping_line1($shipping_address_1, $order_id) {
- $shipping_address = get_post_meta($order_id, '_shipping_address_1', true);
- if (empty($shipping_address)) {
- $house_no = get_post_meta($order_id, '_billing_hausnummer', true);
- if (empty($house_no)) {
- $house_no = get_post_meta($order_id, 'billing_hausnummer', true);
- }
- } else {
- $house_no = get_post_meta($order_id, '_shipping_haus_nummer', true);
- if (empty($house_no)) {
- $house_no = get_post_meta($order_id, 'shipping_haus_nummer', true);
- }
- }
- if (!empty($house_no)) {
- $shipping_address_1 = $shipping_address_1 . ' ' . $house_no;
- }
- return $shipping_address_1;
- }
Add Comment
Please, Sign In to add comment