HTTPS issue on CodePen

HTTPS issue on CodePen
0

#1

Mixed Content: The page at ‘https://s.codepen.io/Aloap/debug/dvjLye/NjrYzwnDQXNA’ was loaded over HTTPS, but requested an insecure XMLHttpRequest endpoint ‘http://api.openweathermap.org/data/2.5/weather?q=Roma&APPID=8da5ea928c9723712bb4bccde75b078e’. This request has been blocked; the content must be served over HTTPS.

How can I solve this problem on CodePen?

Here’s my project: https://s.codepen.io/Aloap/debug/dvjLye/mWAoNbGEBXzr

Thank you!


#2

Hey. Just add an “s” to every http you already have (in the HTML and JS panel). Requests from https must be made to another secure connection.

Also, you won’t need the “https://crossorigin.me/”; the openweather api can be directly loaded over https (i.e.: https://api.openweathermap.org/etc...).


#3

Thank you!
it seems to work, except for something depending on ip-api, I guess.
I’ll try to find out a solution! Thanks a lot for the advice! :slight_smile: