Code to separate fields for custom title
-
Hello, thank you for best checkout plugin.
But I need one option. I need “separate” shipping method field by “free custom field” or free space for custom title for local pickups like:
Shipping method
- DHL
- American Express
Local Pickups
- city one
- city two
- city three
If I use this code: I add text: “Osobní odběr (zdravotnické pot?eby EMPOLAS)” only to field with delivery method. I need add this up to local delivery methods.
add_action(‘woocommerce_after_shipping_rate’, ‘woocommerce_after_shipping_rate_callback’, 10, 1);
if(!function_exists(‘woocommerce_after_shipping_rate_callback’)) {
function woocommerce_after_shipping_rate_callback($method) {
if(‘toret_tcp_doruky’ === $method->id){
echo ‘Osobní odběr (zdravotnické pot?eby EMPOLAS)’;
}
}
}Thank you for your help
- The topic ‘Code to separate fields for custom title’ is closed to new replies.