“包括在 WooCommerce 购物车和结帐中为 {country} 估计的 $x 增值税" [英] "includes $x VAT estimated for {country} "in WooCommerce cart and checkout

查看:17
本文介绍了“包括在 WooCommerce 购物车和结帐中为 {country} 估计的 $x 增值税"的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已将增值税设置为包含数字商品的税费.在我的购物车和结帐中,税款显示在总金额之后:

I've set up VAT as including taxes for digital goods. In my cart and checkout the tax appears after the total amount as:

(包括 $xy 增值税)"

"(includes $xy VAT)"

我更喜欢我在其他商店网站上看到的:

I would rather much prefer what I saw on other shop sites:

(包括为德国估算的 $xy 增值税)"

"(includes $xy VAT estimated for Germany)"

我的问题:

1) 这是根据我使用的主题定制的,是插件还是我可以自己在 WooCommerce 中进行设置?购物车上的估计国家/地区是否按地理位置设置?

1) is this a customization by the theme I'm using, is it a plug-in or can I set this up in WooCommerce myself? Is the estimated country on the cart set up by geolocation?

2) 我可以使用钩子或过滤器将估计税款文本置于价格之前吗?

2) can I position the estimated tax text before the price with a hook or filter?

推荐答案

对于问题 2,试试这个

For question 2 give this a try

add_filter( 'woocommerce_cart_total', 'wc_prefix_text_on_price' ); 

function wc_prefix_text_on_price( $price ) {
    $prefix = 'estimated tax';
    return  $prefix . $price;
}

这篇关于“包括在 WooCommerce 购物车和结帐中为 {country} 估计的 $x 增值税"的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆