anselb / activity-planner

A simple web app for creating itineraries of locations to visit from yelp
2 stars 7 forks source link

JS [Deprecation] getCurrentPosition() no longer work on insecure origin #46

Closed Jeffchiucp closed 6 years ago

Jeffchiucp commented 6 years ago

https://github.com/anselb/activity-planner/blob/5515aada71b4c68e089123d1e9b6883e9a5c96f7/public/javascripts/js-map.js#L70

[Deprecation] getCurrentPosition() and watchPosition() no longer work on insecure origins. To use this feature, you should consider switching your application to a secure origin, such as HTTPS. See https://goo.gl/rStTGz for more details.

See the

Jeffchiucp commented 6 years ago

One of the biggest challenges ran into was running our node server over HTTPS. This was required because our web frontend had to run over HTTPS to get the User geolocation data. If the frontend runs over HTTPS and node runs over HTTP, the browser complains about serving insecure data, and does not display any of the fetched data. When we configured node to run over HTTPS, the browser complained again saying that the server certificate may be fraudulent.

Jeffchiucp commented 6 years ago

Trying to figure out what is the workaround. Going to run our node server locally and opened up the port we used by using ngrok to get an HTTPS link.

Jeffchiucp commented 6 years ago

Find some helpful resource: https://stackoverflow.com/a/37276372/3000566

Jeffchiucp commented 6 years ago

finished requiring https for the website: https://awesome-activities-planner.herokuapp.com