woocommerce

Show subtotal excl. tax, add subtotal tax as separate row on Woocommerce checkout

ε祈祈猫儿з 提交于 2021-02-09 06:47:46
问题 Currently I have all my products set to include tax. Because of rules in my country I would like to have my subtotal without tax, then a line with the amount of tax being paid and then the total with all the taxes (which is already default) In my review-order.php the line <td><?php wc_cart_totals_subtotal_html(); ?></td> gets called. I would like to subtract the tax percentage (21%) from that so ( / 121 * 100). And then a new line which shows the full tax amount so (total - subtotal). 回答1:

WooCommerce seems to only orderby date and not price

天大地大妈咪最大 提交于 2021-02-08 13:43:28
问题 I am loading in variable products via a custom WP_Query $args = array( 'post_type' => 'product', 'posts_per_page' => 100, 'product_cat' => 'beast-balls', 'orderby' => 'date', 'order' => 'desc' ); $loop = new WP_Query( $args ); if ( $loop->have_posts() ) { while ( $loop->have_posts() ) : $loop->the_post(); ?> <div class="product-node cat-beast-balls"> <?php wc_get_template_part( 'content', 'single-product' ); ?> </div> <?php endwhile; } wp_reset_postdata(); This seems to work fine. However, I

How to change the text “Your order” on the checkout

放肆的年华 提交于 2021-02-08 12:13:51
问题 How to change the text "Your order" on the checkout in Woocommerce Checkout from the online shop 回答1: There are a couple of ways. You can use gettext. As far as I can recall, the term you mentioned is translatable. If so, you can go ahead with the following function. Add this in your theme functions.php file (child theme recommended) function custom_wc_translations($translated){ $text = array( 'Your order' => 'Your new phrase', 'any other string' => 'New string', ); $translated = str_ireplace

Woocommerce show product published date on shop page [closed]

旧巷老猫 提交于 2021-02-08 12:13:26
问题 Closed . This question needs to be more focused. It is not currently accepting answers. Want to improve this question? Update the question so it focuses on one problem only by editing this post. Closed 3 years ago . Improve this question I'm looking for solution to display products published date on shop page. I would very greatful for any help. 回答1: Show Product Published Date Shop and Single Page in WooCommerce add the below function in function.php file //WooCommerce Shop Page : Show

Woocommerce show product published date on shop page [closed]

…衆ロ難τιáo~ 提交于 2021-02-08 12:13:13
问题 Closed . This question needs to be more focused. It is not currently accepting answers. Want to improve this question? Update the question so it focuses on one problem only by editing this post. Closed 3 years ago . Improve this question I'm looking for solution to display products published date on shop page. I would very greatful for any help. 回答1: Show Product Published Date Shop and Single Page in WooCommerce add the below function in function.php file //WooCommerce Shop Page : Show

Change default sorting order in woocommerce dashboard screen

ぐ巨炮叔叔 提交于 2021-02-08 12:01:31
问题 I am trying to change the default sorting order in woocommerce admin screen. I am trying the following code to sort the product page by product name by default. /* Sort posts in wp_list_table by column in ascending or descending order. */ function custom_post_order($query){ /* Set post types. _builtin => true returns WordPress default post types. _builtin => false returns custom registered post types. */ $post_types = get_post_types(array('_builtin' => false), 'names'); /* The current post

Woocommerce - Add username to new order email subject line

人走茶凉 提交于 2021-02-08 11:55:25
问题 Is it possible (and if so any help would be much appreciated) to.... Add the logged in username to the 'new order' emails within woocommerce I can add items such as blogname, date, order number etc but need to somehow get the username on the subject line. So it would be if joe blogs is ordering Subject: New order from Joe blogs - Order number #444 I have found some different suggestions but I have no php experience so if someone can point me to a how to guide or help further that would be

Hide auto added gift product from WooCommerce catalog

萝らか妹 提交于 2021-02-08 11:49:24
问题 I have the following scenario that I can not solve, could you guide me, either with a plugin or from code? I have the product A and the product B, which should not appear in the store nor can it be added individually as it is a gift. If someone adds product A to the cart, then the system should add product B. It is like a BOGO, but the problem that I cannot solve is that of the free product that must be invisible and not allow to be purchased individually. 回答1: Based on Auto add to cart a

Cloudfront + Woocommerce - cart not updating

大兔子大兔子 提交于 2021-02-08 11:38:45
问题 I have recently added cloudfront to my wordpress site hosted on AWS. At first my cart would not register any products being added to it - so I made a behaviour in cloudfront to not cache the cart, my account and checkout pages. Now my users can only add a single product at a time - after adding a second it overwrites what was added in intially. I believe it must be a problem with the caching behaviour of cloudfront. can anyone help me with what settings I need to get woocommerce to play nice

How to integrate contact form 7 with woocommerce .?

三世轮回 提交于 2021-02-08 10:46:34
问题 I am just a beginner and don't know alot about coding. I made a conditional order form with the help of contact form 7 wordpress plugin. I am trying to find a plugin or any way where form shows on woocommerce product page without picture and tabs OR after filling the contact form 7, Checkout will be done through woocommerce. Reason for checkout through woocommerce is becuause of the order history and order email of the user. Any idea how to do that .? so far i have tried to put the below code