Enhancements?
-
I don’t see any way to contact you to request/collaborate regarding two enhancement ideas I have, so posting here.
1. My task is to connect product photos to their WooCommerce product.
From your side of the game, a new filter should be enough.
“media_sync_file_import_complete” would be a first guess at a filter name.At the least, the attachment_id would be needed. The data array sent to wp_insert_attachment would be nice to have if available.
I can find the product based on the file name just imported, and go from there (updating post_meta of the product). I would also update the wp_posts.post_parent value of the attachment to reflect the connection. Of course, I would provide you with this code so that you could increase your plugin’s functionality if you like.
2. Allow regeneration of attachment_meta (and resized files) of already imported images. This can be handled in a couple of ways on the front-end, but the core would be the ability to update an existing ‘attachment’. This function should also call the filter mentioned above (or a similar one).
- The topic ‘Enhancements?’ is closed to new replies.