diff options
author | Momo <momorientes@online.de> | 2011-08-05 22:33:13 +0200 |
---|---|---|
committer | Momo <momorientes@online.de> | 2011-08-05 22:33:13 +0200 |
commit | 6cd1e21b3994911c0d3ec705168eb82d73e807a1 (patch) | |
tree | 875ce4dc53473b95914af99872532fe74ca03909 /kachelmann/conditions.pl | |
parent | 89afd781699ad55c79def2865048f096287da876 (diff) |
Added Kachelman to return the current weather situation
Diffstat (limited to 'kachelmann/conditions.pl')
-rw-r--r-- | kachelmann/conditions.pl | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/kachelmann/conditions.pl b/kachelmann/conditions.pl new file mode 100644 index 00000000..feabe6aa --- /dev/null +++ b/kachelmann/conditions.pl @@ -0,0 +1,6 @@ +#!/usr/bin/perl +use XML::Simple; +system("w3m -dump \"http://www.google.com/ig/api?weather=70327-stuttgart&hl=de\" > weather.xml"); +my $xml = new XML::Simple; +my $data = $xml->XMLin("weather.xml"); +print "Draussen ist $data->{weather}->{current_conditions}->{condition}->{data}\n bei $data->{weather}->{current_conditions}->{temp_c}->{data} Grad Celsius\n"; |