最新消息:雨落星辰是一个专注网站SEO优化、网站SEO诊断、搜索引擎研究、网络营销推广、网站策划运营及站长类的自媒体原创博客

woocommerce offtopic - How to do_action after some plugin{woocs} loaded?

programmeradmin0浏览0评论

i am working on simple feature: quantity change -> total price update on a single page. Solution provided here:

Works almost as i want except it doesnt work for variation products with a woocs plugin(currency switcher) installed altogether. I was trying to find out how woocs plugin get's price and only found this lines of code:

$customer_price_format = get_option('woocs_customer_price_format', '__PRICE__');

Digging into that part and searching for woocs_customer_price_format gave me no positive results. Why would i need this price ? Because getting price with $product->get_price() - gets wrong price from price variations.

Only solution (actually its bad) i found is to regexp price from a field that woocs plugin is setting on product page. But that's a problem for me, because i don't know how to run code AFTER woocs plugin loaded.

Tried do_action('wp_loaded|plugins_loaded|after_cart_etc_all_hooks'), but for some time div with woocs plugin classname is undefined.

Is there an action to fire after all plugins loaded in woocommerce ?

发布评论

评论列表(0)

  1. 暂无评论