I have no problem getting the current lat and lng using javascript. But I would like to call the API link in PHP via file_get_contents as following:
<?php
$json = file_get_contents('https://www.googleapis.com/geolocation/v1/geolocate?key=Jsddds6s6sdht43asdsaASasta8962');
?>
Current if I paste the URL in Chrome, I am getting Not Found. Why does this happened?