medias XHR request with wrong scheme
Greetings...
I'm having trouble with accessing media library in the admin area in production. Mixed content error. The request for 'medias' is being made via http: scheme even though APP_URL, APP_ADMIN_URL, and ASSET_URL are all set with the https: scheme.
Any idea how to fix? Thanks!
2 Replies
hey @Pauly is your app url with http or https?
It's https
All other urls and requests are being correctly performed with https. Other than displaying images in the media library, everything else is working.
Thank you for your assistance with this. I never did figure out what the root cause of the issue was, but I managed to get it to work by using: if (env('APP_ENV') === 'production'){URL::forceScheme('https');} One guess is that a handful of URLs are being generated not from the ENV (config) variables but some other way that was getting confused, possibly because I'm running this behind nginx in production. Just a theory but at least I am enjoy some Twill love now! Thanks again.