PHP code example of jiminald / dark-sky-api

1. Go to this page and download the library: Download jiminald/dark-sky-api library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

jiminald / dark-sky-api example snippets



$dark_sky = new \DarkSkyApi\DarkSkyApi('API KEY', 'FGC');


k_sky = new \DarkSkyApi\DarkSkyApi('API KEY');
$forecast = $dark_sky->get_forecast('LATITUDE', 'LONGITUDE');

var_dump($forecast->getHourly());