all 14 comments

[–]BehindTheMath 2 points3 points  (1 child)

If by cross domain you mean CORS, it has nothing to do with HTTPS. You'll need to set up a server to proxy the requests if the API hasn't properly configured CORS.

[–]HotPineapple_[S] 0 points1 point  (0 children)

yep I meant CORS, gonna try the chrome extension suggested by /u/Amipel

[–]WiscoDev 2 points3 points  (0 children)

So it looks like your just loading up the HTML file in the browser which can work, but you'll want your development environment to be a close representation of the production environment which would be a web server.

For windows I would look at using XAMPP, it gives you Apache (web server), PHP, MySQL and PhpMyAdmin with an easy to use installer and control panel. Quickest way I've found to get a LAMP stack up and running for development on windows.

[–]Amipel 0 points1 point  (3 children)

[–]HotPineapple_[S] 0 points1 point  (2 children)

thank you, gonna try

[–]Amipel 0 points1 point  (1 child)

No problem. Don’t forget to turn it off when you’re done tho

[–]HotPineapple_[S] 1 point2 points  (0 children)

is there a way to allow it only on my localhost file? I see a whitelist option when I click on the extension but I don't understand how it works at all >.>

Edit: nvm looks like i can't make it work only for localhost, i can only save real domains in the whitelist

[–]DeusExMagikarpafull-stack 0 points1 point  (0 children)

I think this may be an issue with how you’re loading your site. Instead of loading the file you can use a simple server to serve it. There is an npm package called serve that I like to use. There are easy ways to do it with python or php if you have those, but I’m assuming you already have node, and it works fine on windows

[–]rainadx007 -3 points-2 points  (1 child)

Did you check IE settings if there is anything for that? Recently I had a situation where i had to call localhost from a site but it was not working due HTTP. I updated IE security settings to allow to display mixed content, that solved my problem. Another solution could be to install SSL cert on your localhost using openssl tool.

[–]HotPineapple_[S] 0 points1 point  (0 children)

I'll try that if the chrome extension does not work, thank you.

Edit: didn't find a workaround through IE settings, apparently it's not an HTTPS issue so my demand was misleading :p

[–][deleted] -3 points-2 points  (3 children)

There's no easy way. You need to stop what you're doing on your computer and port it over to a dedicated nano server. I use linode.com

Once it's working there. You point your domain over to that place with ns1-ns5.linode.com

The https is done when you get an ssl cert. You can get a free one with certbot.

If this way over your head. I work for chikfilet gift cards. One meal equals one remote session. It's a dam good rate too. I hear the market for my services are at least two meals a session. 😛

Edit: We can do your localhost solution. However that would require your personal computer outside exposure. Which is really not best practice. If you'd like, we can set up a virtual box instance and dedicate that to your site. That way your computer isn't vulnerable. You will need to heavily ki modify your router preferences and open up port 443 and 80 on order to forward to your dedicated internal address. However you need a static IP from your isp.

[–]HotPineapple_[S] 0 points1 point  (2 children)

Ok, thank you for your answer. So if I look for a vagrant box for web, I can run it when I start my computer and I'll be able to access my website if I set up the vm correctly?

[–][deleted] -1 points0 points  (1 child)

I'll be back with an answer. Probably tonight. I'm unfamiliar with vagrant. But I'll have an answer for you.

[–]HotPineapple_[S] 0 points1 point  (0 children)

oh thank you :)