• Resolved RenderWarrior

    (@web4people)


    Hello,

    we’re developing an automation for a customer, where we get data from CSV files, and then we insert it into Woocommerce.

    We’re importing the color attributes, and we can setup the color names, their slug, but how can I match an imager to the color attribute? Actually with your plugin I’ve just to manually upload an image. But when I save my attribute, I think you save the value somewhere with a field name. I’d like to know if I can setup the image to the attribute via API, if so, what field I’ve to send to the API and what value (the image ID? or the file path?)

    Thanks a lot!

    Best regards

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Support Mamunur Rashid

    (@mamunur105)

    We never tested like you .

    I think you want to upload csv for this image : https://prnt.sc/2ejTXC3eia4y

    This is the meta key and the meta field

    https://prnt.sc/q0Xj3SneOwzF

    Thank you.

    Thread Starter RenderWarrior

    (@web4people)

    Hello! Well, adding an entry to the wp_termmeta works.

    I used the same image for the same attribute in 2 languages and it works too.

    Of course, it’s a direct SQL code from my PHP page, not a REST API call, but it works.

    Of course, I’ve to add the image to the Media, get the ID and use it for the SQL code.

    Thanks

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Setting an image for a color attribute via WooCommerce API’ is closed to new replies.