Closed i-make-robots closed 8 years ago
Never mind! I was following http://stackoverflow.com/questions/29635202/woocommerce-downloadable-files-disappear-after-database-restore/36322809#36322809 which is out of date.
The correct format for the change is
$wc_api->products->update( $product_id, array('downloads'=>array(array('file'=>$newURL))));
Thank you for this sweet sweet library. You totally rock.
My keys were set up with read/write. I call
the returned $obj displays the old URL, and the product['updated_at'] value remains unchanged.
What am I doing wrong?