Jump to content

Is there a way to force a one-time re-generation of image size variations?


reed
 Share

Recommended Posts

A while back I added webp support to arthistoryproject.com, but didn't see a ton of image size improvement. Then today I read this post by the genius horst, and realized I could tweak webp quality settings in config.php. I've made some changes, and new webp renders are WAY smaller. Fantastic!

But now I'm wondering if there's a way to programmatically delete/overwrite previously rendered image variations, either site-wide or page-by-page. But of course, only once per page/image. Does that make sense? Thanks so much for any ideas! 

Reed 

Link to comment
Share on other sites

If you just want to delete all WebP files you also could do this via the command line in your site/assets/files:

find . -name "*.webp" -type f -delete

Source

But only if you don't have WebP files manually uploaded in your file fields, so be careful.

The module posted above is more safe I think. ?

There was also a receipe by Ryan a while ago, but I cannot find it.

Link to comment
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...