Display specific product attributes under product title in Woocommerce archive pages
问题 In woocommerce, I would like to show some product attributes on shop page under the product titles. This product attributes are "year", "model" and "oil". This is what I have for now: add_action('woocommerce_shop_loop_item_title', 'wh_insertAfterShopProductTitle', 15); function wh_insertAfterShopProductTitle() { global $product; $abv = $product->get_attribute('pa_year'); if (empty($abv)) return; echo __($abv, 'woocommerce'); } Any help is appreciated. 回答1: To display "year", "model" and "oil"