how to change img url through middleware

Posted 2 years ago by ctf0

so lets say u have an img over s3, which when used with


you would get something like


and now i started using cloudfront and cuz the CNAME thing is not working and gives errors, so i was thinking of making a middleware that auto change that url to something else like


so is that possible ?

Please sign in or create an account to participate in this conversation.

Laracasts Mascot

Hi, Have We Met Yet?

Did you know that, in addition to the forum, Laracasts includes well over 1000 lessons on modern web development? All for the price of one lunch out per month.

Sign Me Up


Reply to

Use Markdown with GitHub-flavored code blocks.