D
D
Denis2017-08-05 15:07:21
PHP
Denis, 2017-08-05 15:07:21

How to display product attribute name/value in Woocommerce?

How to display product attribute name/value in Woocommerce?
ef90f8e907054aabbdc7e92233188019.png

Answer the question

In order to leave comments, you need to log in

1 answer(s)
W
WordPress WooCommerce, 2017-08-05
@maxxannik

It should appear on the product page itself.
If necessary, in an arbitrary place, that is, the get_attributes method
https://docs.woocommerce.com/wc-apidocs/class-WC_P...
The WC_Product object can be obtained by post_id through the function wc_get_product($post_id);

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question