• Resolved DRHughes00

    (@drhughes00)


    Hi, hope this is the right place for this.

    I am writing some code using the REST API for Woocommerce to add new products.

    All is well, except that I cannot get the image to load in the correct place – the image loads, but it appears under “additional images” rather than the product image.

    This is the snippet that loads the image into the parameters file:

    $image = $this->API_setProductImage($partnumber);
            $this->product_array['images'][0]['src'] = $image;
            $this->product_array['images']['position'] = 0;

    I have tried various options for this but no luck – anyone else had this or can tell me where I am going wrong?

    Thanks
    Dennis

Viewing 3 replies - 1 through 3 (of 3 total)
Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘API Product Create’ is closed to new replies.