我正在使用主题突出显示,希望将产品价格移动到“添加到购物车”按钮的左侧。目前,我的产品价格在按钮上方,如下图所示:
我已经在这个名为“Snippets”的自定义插件中添加了一些php,从而改变了价格元素。它将其放在按钮的正上方,而不是“画布上的丙烯酸”文本的上方。代码如下:
remove_action( \'woocommerce_single_product_summary\', \'woocommerce_template_single_price\', 10 );
add_action( \'woocommerce_single_product_summary\', \'woocommerce_template_single_price\', 25 );