HomePage › Forums › Themes Support › Freshio – Organic & Food Store WordPress Theme › Translate “No products in the cart”
- This topic has 7 replies, 2 voices, and was last updated 2 days, 6 hours ago by
Billy Nguyen.
-
AuthorPosts
-
April 7, 2021 at 3:42 pm #7749
Hello.
I need help for translate “No products in the cart” to another language. I change in Loco Translate but the text not change.
April 8, 2021 at 9:55 am #7779Hi there,
About this issue, please send Admin web account for me, I will check and try to help you.
April 8, 2021 at 1:48 pm #7792Please explain how.
April 8, 2021 at 2:13 pm #7797Hi,
I need to check your website, then find the cause and come up with a solution for you. Are you ok?/
April 8, 2021 at 2:27 pm #7803I am working on a local server without internet access
The problem:
when I put the cursor over the cart icon in the menu I get a message “No products in the cart”, this is the text that I cannot translate.
April 8, 2021 at 3:22 pm #7807Hi,
Some text will be lost when translating so that you need to override this function and edit it. Please use this function and add into file functions.php:
function freshio_cart_link() { ?> <a class="cart-contents" href="<?php echo esc_url( wc_get_cart_url() ); ?>" title="<?php esc_attr_e( 'View your shopping cart', 'freshio' ); ?>"> <?php /* translators: %d: number of items in cart */ ?> <span class="count"><?php echo wp_kses_data( sprintf( _n( '%d', '%d', WC()->cart->get_cart_contents_count(), 'freshio' ), WC()->cart->get_cart_contents_count() ) ); ?></span> <?php echo wp_kses_post( WC()->cart->get_cart_subtotal() ); ?> </a> <?php }
Then edit text.
April 8, 2021 at 5:45 pm #7818I put the code in to function.php in my child theme but nothing change
April 9, 2021 at 9:47 am #7834Hi,
#Case 1: Please go to Loco translate -> Plugins -> Select Woocommerce -> Search text and add translate.
#Case 2: Override file min-cart.php
Create folder : woocommerce/cart on child-theme, then copy file min-cart.php on main theme into this folder.
After, change edit text. -
AuthorPosts
You must be logged in to reply to this topic.