Skip to content
Advertisement

Tag: hook-woocommerce

Get data from apply_filters(‘prefix_xml_feeds_productname_variant’) function in WooCommerce

I’m totally new to WordPress and WooCommerce, so apologies for the poor explanation. I have this code: And need to display $vars->ID in my function: So I got: How can I access $vars variable value in my callback function? Answer As you can see apply_filters( ‘prefix_xml_feeds_productname_variant’, $text, $product_item->ID, $vars->ID ); contains 3 parameters So you could use it like More

Advertisement