Answers for "get variation name and id for a product"

0

get variation id from by product id

$product = wc_get_product($product_id);
$variations = $product->get_available_variations();
$variations_id = wp_list_pluck( $variations, 'variation_id' );
Posted by: Guest on December-17-2020
0

get variation id from by product id

$product = wc_get_product($product_id);
$current_products = $product->get_children();
Posted by: Guest on December-17-2020

Code answers related to "get variation name and id for a product"

Browse Popular Code Answers by Language