Thursday, December 23 2021
  1 Replies
  53 Visits
  Subscribe
Media Rename transforms media filenames to media slugs. But is there also an option to modify filenames on upload like i.e. Media File Renamer ? I haven't seen this anywhere in your promotion or documentation.

What I would want is that my uploaded file "Perfect black-white Photography.jpg" with the intentional hyphen and lower case in "black-white" would results in a:
- media title Perfect black-white Photography (case and hyphen preserved)
- a filename perfect-black-white-photography.jpg (transformed to lowercase)
- hence a filepath /wp-content/uploads/perfect-black-white-photography.jpg or if in a folder then something like /wp-media-dir/my-project/perfect-black-white-photography.jpg
- a media slug /perfect-black-white-photography or if in a folder then a media slug /my-project/perfect-black-white-photography

And should I use synchronization ("server directory to WP media directory" or "Dropbox to WP media directory") and update the file "Perfect Black-White Photography.jpg" it should work with syncing. Because first the file change triggers an API update and if that file again gets transformed to perfect-black-white-photography.jpg and that file already exists at the destination, this means "ok please update it" as the source file is newer than the destination file.

I know implementing a filename-transformation and a reliable sync surely ain't that easy, but at least tell me what you think of it, whether it has potential.
A
4 months ago
Hi,

Thanks for contacting us here about this extension.

What I would want is that my uploaded file "Perfect black-white Photography.jpg" with the intentional hyphen and lower case in "black-white" would results in a:
- media title Perfect black-white Photography (case and hyphen preserved)
- a filename perfect-black-white-photography.jpg (transformed to lowercase)
- hence a filepath /wp-content/uploads/perfect-black-white-photography.jpg or if in a folder then something like /wp-media-dir/my-project/perfect-black-white-photography.jpg
- a media slug /perfect-black-white-photography or if in a folder then a media slug /my-project/perfect-black-white-photography


Our plugin is based on the WP media library default. We just create virtual folders to manage media in the library.
So all paths of images uploaded using WP Media Folder will be the same as the original one.
It's possible to set all upper or lowercase in our plugin only, hyphens can be removed not added.

And should I use synchronization ("server directory to WP media directory" or "Dropbox to WP media directory") and update the file "Perfect Black-White Photography.jpg" it should work with syncing. Because first the file change triggers an API update and if that file again gets transformed to perfect-black-white-photography.jpg and that file already exists at the destination, this means "ok please update it" as the source file is newer than the destination file


I'm not sure what do you mean exactly here. Files in cloud folders will actually store on the cloud server.
It's just indexing file information in the Media library so it will free your server space.
And you can insert directly your cloud files into your posts/pages.


Thanks a lot!
Best Regards,
  • Page :
  • 1
There are no replies made for this post yet.
Be one of the first to reply to this post!