Hook for Woocommerce checkout fields

Your code seems to be correct and should generally work for all fields. However, the ‘billing_postcode’ and ‘billing_city’ fields may be processed differently or not be considered required based on the customer’s country or other settings, which could explain why they’re not being modified. If you want to ensure a message appears for all fields, … Read more

How to get all child categories of current parent category in product detail page of woocommerce? [closed]

This is how you display all child terms of a parent term: $term_id = 8; // id of your clothes category $taxonomy_name=”your_taxonomy”; // e.g. ‘category’ $termchildren = get_term_children( $term_id, $taxonomy_name ); if ( !empty($termchildren) ) { foreach ($termchildren as $termchild) { $term = get_term_by( ‘id’, $child, $taxonomy_name ); // Do things } } See https://developer.wordpress.org/reference/functions/get_term_children/