2017 © Pedro Peláez
 

silverstripe-module silverstripe-weatherforecast

Retrieve a weather forecast (uses openweather)

image

nyeholt/silverstripe-weatherforecast

Retrieve a weather forecast (uses openweather)

  • Wednesday, July 20, 2016
  • by nyeholt
  • Repository
  • 1 Watchers
  • 0 Stars
  • 3,259 Installations
  • HTML
  • 0 Dependents
  • 0 Suggesters
  • 3 Forks
  • 0 Open issues
  • 1 Versions
  • 8 % Grown

The README.md

SilverStripe weather forecast module

Usage

In your project .yml config, (*1)

---
Name: weather-config
After: weatherforecast/*
---
Injector:
  OpenWeatherService:
    properties:
      key: {your key here}

From your code, call the following. The LocationID will need to be looked up from the openweather site., (*2)

Requirements::css('weatherforecast/owfonts/css/owfont-regular.min.css');
$forecast = singleton('OpenWeatherService')->forecastFor($locationID);

PLEASE NOTE

The requirements of OpenWeatherMaps mean you must provide attribution on your site for using the service., (*3)

The Versions

20/07 2016

dev-master

9999999-dev

Retrieve a weather forecast (uses openweather)

  Sources   Download

BSD-3-Clause

The Requires

 

silverstripe weather forecast