We have a need to move an image media file from one profile to another. The ideal function would be a rename because there is no functional need to read and write the file - just to literally change the hosting profile.
Basically I want like to build a function like jrCore_rename_media_file($profile_id, $current_name, $new_name); but with a $from_profile_id and a $to_profile_id parameter instead of simply $profile_id.
My concern is twofold:
1. Want to avoid reading and writing the image file if possible (no need to consume the needed resources)
2. Want to implement a future-proof solution. That is, to avoid accessing volatile functions.
How would you recommend I approach this problem?
--
TiG
updated by @tig: 04/20/19 12:05:59PM