2017 © Pedro Peláez
 

library weather-forecast-php

PHP wrapper for the Dark Sky API (formerly Forecast.io)

image

sohelrana820/weather-forecast-php

PHP wrapper for the Dark Sky API (formerly Forecast.io)

  • Sunday, July 29, 2018
  • by sohelrana820
  • Repository
  • 1 Watchers
  • 1 Stars
  • 5 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 1 Forks
  • 0 Open issues
  • 2 Versions
  • 0 % Grown

The README.md

weather-forecast-php

weather-forecast-php is php wrapper implementation of Dark Sky Api (formerly Forecast.io), (*1)

Installation

Installation is really easy through composer, (*2)

composer require sohelrana820/weather-forecast-php

Usage

```php <?php, (*3)

use SohelRana820\Forecast\Forecast;, (*4)

$forecast = new Forecast(API_KEY); $forecast->setLatitude(DEFAULT_LATITUDE); $forecast->setLongitude(DEFAULT_LATITUDE); $response = $forecast->request();, (*5)

// Retrieve the current data var_dump($response->getCurrentlyData());, (*6)

// Retrieve the hourly data var_dump($response->getHourlyData());, (*7)

// Retrieve the daily data var_dump($response->getDailyData());, (*8)

// Retrieve weather flags var_dump($response->getFlags());, (*9)

```, (*10)

How to set optional parameters.

This library allow to set all of their optional parameters (lng, units, etc) php <?php $forecast->setOptions($optionsArray = ['units' => 'si']); You can pass all optional parameter as array . See there all optional parameter official documentation. test, (*11)

The Versions

29/07 2018

dev-master

9999999-dev https://github.com/sohelrana820/weather-forecast-php

PHP wrapper for the Dark Sky API (formerly Forecast.io)

  Sources   Download

MIT

The Requires

 

The Development Requires

by Avatar sohelrana820

weather forecast dark sky api forecast php api forecast php wrapper forecast.io php wrapper

14/02 2017

1.0.0

1.0.0.0 https://github.com/sohelrana820/weather-forecast-php

PHP wrapper for the Dark Sky API (formerly Forecast.io)

  Sources   Download

MIT

The Requires

 

The Development Requires

by Avatar sohelrana820

weather forecast dark sky api forecast php api forecast php wrapper forecast.io php wrapper