Skip to content
● Critical PHP security fixes are out: update PHP on your Grav sites. What to do →

Override api class

Started by Thomas Vantuycom 5 years ago · 1 replies · 745 views
5 years ago

I'd like to override the \Grav\Common\Page\Medium\ImageMedium api class to change the url function so that images are served from Cloudinary. How would one go about this in a plugin?

5 years ago

As a starter, I'd check onMediaLocate event hook. But I guess you'd just have to debug what you get there 🤔 Not much info about it

Suggested topics

Topic Participants Replies Views Activity
Plugins · by DrPen, 2 days ago
1 60 1 hour ago
Plugins · by renedebaaij, 1 week ago
1 132 3 days ago
Plugins · by Thomas, 6 days ago
1 140 5 days ago
Plugins · by complanar, 4 weeks ago
6 468 3 weeks ago
Plugins · by BenLaKnet, 3 weeks ago
1 289 3 weeks ago