I need some help in WooCommerce Shipping method. How can I show the value of shipping class on the cart page. Let me explain little bit my problem. I added a flat rate to charge shipping for some products i.e. chairs €7 which is working perfect and show on cart page as => Shipping: Flat rate: €7 but I̵…
Tag: wordpress
Detect dashboard of WooCommerce “my account” pages
How can I detect if the “myaccount/my-account.php” template is used on the Dashboard. Currently I use: query_vars[‘page’]) ) { ?> <a href="/…
WooCommerce – Custom thumbnails and default fall back image placeholder
I just want to insert a wrapper to the woocommerce_get_product_thumbnail I can see that my wrapper appeared but It doesn’t have a fall back image if there’s no image. How do I output the default …
Adding a “return to shop” button on single product pages that leads back to product parent category
My client wants to place a “return to shop” button on single product pages in WooCommerce that leads back to the previous page and not the main shop page. I have explained that all browsers have back buttons but they are dead set on having this button. I’ve even mentioned activating breadcru…
How can I remove the product/inventory count from the shop page on Woocommerce?
Do anyone know how I can remove the number of current available stock that is shown on my Woocommerce product page next the the title of the product? I guess this has changed since the recent Woocommerce update because adding the code snippet no longer works. Does anyone have a solution to this? All suggestio…
WooCommerce – unset ” removed notice…” on cart page
actions and filters. On my WooCommerce site I get the following message when I remove a product from the shopping cart: Looking over WooCommerce source code I have found a conditional statement in class-wc-form-header.php as part of the function update_cart_action(): But I can’t find the way to use it f…
How to show SKU before woocommerce product title on archive page
I’m trying to show the SKU before title of product in woocommerce. Here is a code what I’m trying bellow code show the SKU after price on Woocommerce archive page. But is there any hook available to show it before the product title on archive page ? I use woocommerce_get_price_html this hook to sh…
PHP: How to extract() values from an associative array with hyphens/dashes in their keys?
I’m referring to this question. Is it possible to extract() values from an associative array with hyphens/dashes in their keys by now? It’s about an older version of the WordPress Shortcode API. Example: Answer It is still not possible. However, for the PHP.net engine, I have an RFC under discussi…
Add custom field data to WooCommerce order
I have a custom field on my WooCommerce single product. It sends to the cart fine, it displays on checkout fine, it shows in the order in the dashboard fine. What I am now trying to do is set the value as a custom field in the order page so I am able to amend the text when I need
WordPress add responsive srcset header image to theme
WP introduced support for srcset in version 4.4 for Thumbnails and Post images. But I can’t find a way to make the page header responsive. Here is how I embed the Page header: This loads the header image (which can be uploaded in the backend > Design > Customise) in an src. But I’d rather in…