Keys →
Functions ↓
function getWeather ( $lat, $lon, $excl='minutely,hourly,alerts' ) {#-k geo weather#-p $lat - req - Latitude#-p $lon - req - Longtitude#-p $excl - opt - items to exclude; default 'minutely,hourly,alerts' if ($lat[0] == "+") $lat = substr($lat,1); $weatherReq = 'https://api.openweathermap.org/data/2.5/onecall?'; $api = 'bd885445b285a9798b099d1ebcdc7e54'; $str = 'lat=' . $lat . '&lon=' . $lon . '&exclude=' . $excl . '&units=imperial' . '&appid=' . $api; $a = file_get_contents ( $weatherReq . $str ); $w = json_decode ( $a, true ); return $w; }?>