Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- function my_em_stripe_session_vars($stripe_checkout,$EM_Booking){
- $stripe_checkout['locale'] = "ja";
- $stripe_checkout['metadata'] = array( 'first_name' => $EM_Booking->get_person()->first_name, 'last_name' => $EM_Booking->get_person()->last_name, 'customer_email' => $EM_Booking->get_person()->user_email );
- $stripe_checkout['payment_intent_data']['shipping'] = array (
- 'address' => array(
- 'line1' => $EM_Booking->booking_meta['registration']['billing_address_1'],
- 'city' => $EM_Booking->booking_meta['registration']['billing_city'],
- 'country' => $EM_Booking->booking_meta['registration']['dbem_country'],
- 'postal_code' => $EM_Booking->booking_meta['registration']['billing_postcode'],
- ),
- 'name' => $EM_Booking->booking_meta['registration']['first_name'].' '.$EM_Booking->booking_meta['registration']['last_name'],
- 'phone' => $EM_Booking->booking_meta['registration']['phone'],
- );
- return $stripe_checkout;
- }
- add_filter('em_gateway_stripe_checkout_session_vars', 'my_em_stripe_session_vars', 100,2);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement