Quantcast
Channel: Get product attribute for Simple product in WooCommerce - WordPress Development Stack Exchange
Browsing latest articles
Browse All 3 View Live

Answer by Nathan for Get product attribute for Simple product in WooCommerce

Building on Loic's answer for an attribute of pa_manufacturer:if ( get_post_type( $post ) === 'product'&& ! is_a($product, 'WC_Product') ) { $product = wc_get_product( get_the_id() ); // Get...

View Article


Answer by LoicTheAztec for Get product attribute for Simple product in...

You will use the WC_Product method get_attributes() that returns an array like:global $product;if ( get_post_type( $post ) === 'product'&& ! is_a($product, 'WC_Product') ) { $product =...

View Article


Get product attribute for Simple product in WooCommerce

I need to get product attributes from product in WooCommerce, type product Simple product, some product can be as dropdown, but much options as radio button. How I can do this? How it possible? With...

View Article
Browsing latest articles
Browse All 3 View Live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>