• Resolved kavalants

    (@kavalants)


    Hello.
    I use this extension for WooCommerce. If I add images for variation manually it works great, but if I try to add images programmatically, it doesn’t work for me and I don’t get any error while debug.
    I used method set_gallery_image_ids($image_ids : array) for class WC_Product_Variation. The documentation states that this is correct.
    Code looks like:

    $wcVariation = new WC_Product_Variation($wcVariationPostId);
    $img_ids = [11318, 11319, 11220, 11321];
    $wcVariation->set_gallery_image_ids($img_ids);
    

    I will be grateful for a hint where to look for the problem.

    • This topic was modified 3 years, 8 months ago by kavalants.
    • This topic was modified 3 years, 8 months ago by kavalants.
Viewing 2 replies - 1 through 2 (of 2 total)
  • Hello,
    This forum is for checking WooCommerce core issues. You are using a premium plugin and you should discuss your problem with the plugin developer via a ticket.

    Good luck

    Plugin Support wpnomad a11n

    (@wpnomad)

    Hi @kavalants ,

    WooCommerce Additional Variation Images is our premium extension supported directly via WooCommerce.com.
    Please contact us via this contact form through the WooCommerce.com account that was used for purchasing the extension, and we’d be happy to help you.

    • This reply was modified 3 years, 8 months ago by wpnomad a11n.
Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘additional gallery images per variation on variable products’ is closed to new replies.