When changing ($woocommerce->customer->get_billing_postocode()); to ($woocommerce->customer->get_billing_phone()); it stops working!

Question

So I have a plugin I am upgrading alone – i am not a pro but can maybe someone help me with this problem:

The code goes like this:
// Get settings prior to any processing

if (shift8_wooblock_check_options()) {

    // Pull the settings for processing
    $gateways_remove = array_map( 'esc_attr', get_option('wc_settings_tab_shift8_wooblock_gateway') );
    $postal_codes = explode(" ", esc_attr( shift8_wooblock_sanitize(get_option('wc_settings_tab_shift8_wooblock_postals') )));
    $user_postal = shift8_wooblock_sanitize($woocommerce->customer->get_billing_postcode());
    $ban_time = (!empty(esc_attr(get_option('wc_settings_tab_shift8_wooblock_daysremember'))) ? esc_attr(get_option('wc_settings_tab_shift8_wooblock_daysremember')) : 30);

The problem I have is when i change get_billig_postcode to get_billing_email it doesnt do anything and it stops working. The only difference between them is that postcode it TYPE text and phone is TYPE tel. Do you guys know what is wrong?

Thank you!

0
, , , , Mark120 6 months 0 Answers 64 views 0

Leave an answer