在“我的帐户”页面的WooCommerce订阅表下添加按钮
我正在使用WooCommerce,并试图在MyAccount页面中的subscription表下添加一个按钮 我已尝试使用此代码,但不起作用:在“我的帐户”页面的WooCommerce订阅表下添加按钮,woocommerce,subscriptions,Woocommerce,Subscriptions,我正在使用WooCommerce,并试图在MyAccount页面中的subscription表下添加一个按钮 我已尝试使用此代码,但不起作用: add_action('woocommerce_subscription_details_after_subscription_table', 'add_switch_button'); function add_switch_button() { echo "something; } 你能帮帮我吗?刚刚错
add_action('woocommerce_subscription_details_after_subscription_table', 'add_switch_button');
function add_switch_button() {
echo "something;
}
你能帮帮我吗?刚刚错过了你代码中“某事”之后的结束语
add_action('woocommerce_subscription_details_after_subscription_table', 'add_switch_button');
function add_switch_button() {
echo "something";
}
使用当前版本的WooCommerce和WooCommerce订阅进行测试。您使用的是过时的模板吗?我使用的是WooCommerce订阅插件最新版本提供的查看订阅模板