从WooCommerce电子邮件中删除货到付款说明 [英] Remove Cash On Delivery Instructions From WooCommerce Emails
问题描述
这是我的电子邮件当前的样子:
Here is what my email looks like currently:
我花了一些时间尝试删除此内容:
'Pay wish cash upon arriving to destination.'
I have spent some time trying to remove this:
'Pay wish cash upon arriving to destination.'
但是如果不删除其他内容,就无法使其消失.
But cannot make it go away without removing other stuff.
请帮助.
谢谢.
推荐答案
—更新1 —
在后端,如果您转到WooCommerce>设置>结帐>货到付款(标签),您将看到:
In backend, if you go to WooCommerce > settings > Checkout > Cash on Delivery (tab), you will see:
您将可以删除到达目的地后支付愿望现金".说明消息,或将其替换为更方便的消息.
You will be able to remove "Pay wish cash upon arriving to destination." instructions message, or to replace it with something more convenient.
您可以尝试使用WordPress gettext()
函数将以这种方式删除您的文本:
You could try to use the WordPress gettext()
function that will remove your text this way:
add_filter( 'gettext', 'removing_email_text', 10, 3 );
function customizing_checkout_text( $translated_text, $untranslated_text, $domain )
{
if ( 'Pay wish cash upon arriving to destination.' == $untranslated_text ) {
$translated_text = __( '', $domain );
}
return $translated_text;
}
此代码位于您的活动子主题(活动主题或任何插件文件中)的function.php文件中.
This code goes in function.php file of your active child theme (active theme or in any plugin file).
您还可以用其他内容替换文本.
You can also replace the text by something else.
这篇关于从WooCommerce电子邮件中删除货到付款说明的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!