2

Using Drupal 8, I want to rename and clean all filenames, e.g. If someone uploads file named like this Screen Shot 2016-03-29 at 1.13.21 PM.jpg, I want to clean it so that convert all spaces to dashes - and make everything lowercase, So I should get screen-shot-2016-03-29-at-1.13.21-pm.jpg.

I want to do this on image upload dialog form of CKEditor.

  • Try drupal.org/project/filefield_paths – user21641 Mar 29 '16 at 9:50
  • filefield_paths works only for fields attached to content types. I want similar solution for inline images. – otarza Mar 29 '16 at 11:29
0

Try one of the working patches on this page. Look at the answer to this similar question. Use a test installation or backup before trying to patch Drupal core. (If it works well for you, you will probably need to patch the core at every core update, unless this option is making it into Drupal 8.5.)

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.