We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent e780f08 commit e57313aCopy full SHA for e57313a
README.md
@@ -25,9 +25,15 @@ require('path/to/vendor/autoload.php');
25
$weatherbit = new \Attogram\Weatherbit\Weatherbit();
26
27
try {
28
+ // Always set your API Key
29
$weatherbit->setKey('YOUR-WEATHERBIT-API-KEY');
30
+
31
+ // Set location using one of the setLocationBy*() functions
32
$weatherbit->setLocationByCity('Amsterdam', 'NL');
- $currentWeather = $weatherbit->getCurrent(); // Gets array of current weather data
33
34
+ // Gets array of current weather data
35
+ $currentWeather = $weatherbit->getCurrent();
36
37
} catch (Exception $exception) {
38
exit('Error: ' . $exception->getMessage());
39
}
0 commit comments