How do i display zip code options during checkout [closed]

The postcode field was hidden for Nigeria in 3.5, you can see the reasoning given here: https://github.com/woocommerce/woocommerce/issues/21055 While the Nigeria Postal Service (http://nipost.gov.ng/) introduced Postal Codes a few years ago, they aren’t being used by hardly anyone. Nobody knows their postal codes as the implementation is very convoluted and nothing was done to sensitize the … Read more

How to edit checkout page? [closed]

Copy the file “/plugins/woocommerce/templates/checkout/thankyou.php” to your theme or child theme (“/yourtheme/woocommerce/checkout/thankyou.php”). And then you will find this code esc_html__( ‘Thank you. Your order has been received.’, ‘woocommerce’ ) Change it to whatever you like.

Adding new divs with custom classes to products on WooCommerce shop page [closed]

Why not edit the template file instead of using hooks? https://github.com/woocommerce/woocommerce/blob/3.8.0/templates/content-product.php This template can be overridden by copying it to yourtheme/woocommerce/content-product.php. A small example <li <?php wc_product_class( ”, $product ); ?>> <div class=”col-md-5 offset-md-1″> <?php /** * Hook: woocommerce_before_shop_loop_item. * * @hooked woocommerce_template_loop_product_link_open – 10 */ do_action( ‘woocommerce_before_shop_loop_item’ ); /** * Hook: woocommerce_before_shop_loop_item_title. * * … Read more

Get $order in wp_head

Let’s check both hooks. The woocommerce_thankyou hook is added on line 80 of thankyou.php file. The hook is getting $order->get_id() as an argument. So, you have access to the order ID in when you hook to woocommerce_thankyou in your first example. But the wp_head action which is loading from wp_head() function doesn’t have any argument. … Read more