buster808 Posted August 22, 2019 Share Posted August 22, 2019 Hi is there a way hyphens can be added automatically when renaming images so I don't have to type them in. Just like when you name a page. Thanks Link to comment Share on other sites More sharing options...
dragan Posted August 22, 2019 Share Posted August 22, 2019 Interesting related stuff here: And here's a module: http://modules.processwire.com/modules/process-custom-upload-names/ But I'm not sure if you really mean "change after renaming" or "use a custom formatter after uploading". Should the description automatically be generated from the filename, or vice versa? 1 Link to comment Share on other sites More sharing options...
buster808 Posted August 22, 2019 Author Share Posted August 22, 2019 Thanks Dragan I would like the filename automatically generated from the description. description: lets have a party (becomes below) image: lets-have-a-party.jpg Just like when you add the url name for the page Link to comment Share on other sites More sharing options...
dragan Posted August 22, 2019 Share Posted August 22, 2019 In that case, I guess you'd have to look into using hooks. But digging deeper into @adrian's module description linked before, it seems there's an option that will do just what you are looking for: Quote If 'Rename on Save' is checked files will be renamed again each time a page is saved (admin or front-end via API). WARNING: this setting will break any direct links to the old filename in your template files. However, images inserted into RTE/HTML fields on the same page will have their links automatically updated. I have never used this myself, so I guess you should simply try it out and see if it works for you... 1 Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now