Documentation

CurrentWeather
in package

Provides simple interface for reading and generating information on current weather conditions.

Current valid properties are:

  • temp, temperature, temperatureF - int the temerature in Fahrenheit
  • tempC, temperatureC - int the current temperature in Celsius
  • url - string forecast link (back to weather.gov)
  • icon - string simple icon name

Current valid methods are:

  • isRaining() - bool
  • isStorming() - bool
  • isSnowing() - bool
  • isCloudy() - bool

The class also supports 'toString', so you can echo the class to get a text representation of the current conditions:

echo $currentWeather; \ 'Clear'

Table of Contents

$created_at  : mixed
$properties  : mixed
$url  : mixed
__call()  : mixed
__construct()  : mixed
__get()  : mixed
__isset()  : mixed
__sleep()  : mixed
__toString()  : mixed
icon()  : mixed
string()  : mixed

Properties

Methods

__call()

public __call(mixed $f, mixed $v) : mixed
Parameters
$f : mixed
$v : mixed
Return values
mixed

__construct()

public __construct(mixed $p, mixed $u) : mixed
Parameters
$p : mixed
$u : mixed
Return values
mixed

__get()

public __get(mixed $k) : mixed
Parameters
$k : mixed
Return values
mixed

__isset()

public __isset(mixed $k) : mixed
Parameters
$k : mixed
Return values
mixed

__toString()

public __toString() : mixed
Return values
mixed

Search results