API http protocol causes the mixed content error

Json2020
Posts: 1
Joined: Tue Jul 21, 2020 12:05 pm

API http protocol causes the mixed content error

Post by Json2020 »

Hi. I'm creating a web application showing stats from a farming simulator server for myself and friends. I have access to XLM files, but when I fetch the data it works only on localhost. My hosting(netlify, but others too) uses the HTTPS protocol, but developer provides XML data using HTTP protocol and it causes the mixed content error. Is there any chance to make it works on the HTTPS? Why can't they serve the data using safer protocol? Will it be changed in the future? I'm using vanilla JavaScript with no backend.
Minecraftchest1
Posts: 14
Joined: Sun Sep 13, 2020 11:37 pm

Re: API http protocol causes the mixed content error

Post by Minecraftchest1 »

You have to seeve the content using ssl/tls (https). You can use a reverse proxy such as nginx ir haproxy to make it support tls.
Post Reply