summaryrefslogtreecommitdiffstats
path: root/kachelmann/wetter
diff options
context:
space:
mode:
authorroot <root@filebitch>2011-08-28 18:28:51 +0200
committerroot <root@filebitch>2011-08-28 18:28:51 +0200
commit0512b4ace532f81fec314c417f9afea565754001 (patch)
tree8c6522b5e06d187adf360090b812c306e99d59ae /kachelmann/wetter
parent8678f7ce47ed62c9db5446021955b89abbe3ab60 (diff)
parent7bf33493aa27a4462841eb8aa42eda5b974010b7 (diff)
Merge branch 'master' of https://github.com/krebscode/painload
Diffstat (limited to 'kachelmann/wetter')
-rwxr-xr-xkachelmann/wetter6
1 files changed, 6 insertions, 0 deletions
diff --git a/kachelmann/wetter b/kachelmann/wetter
new file mode 100755
index 00000000..957e13e2
--- /dev/null
+++ b/kachelmann/wetter
@@ -0,0 +1,6 @@
+#!/usr/bin/perl
+use XML::Simple;
+my $result = `w3m -dump "http://www.google.com/ig/api?weather=70327-stuttgart&hl=de"`;
+my $xml = new XML::Simple;
+my $data = $xml->XMLin($result);
+print ("$data->{weather}->{current_conditions}->{condition}->{data} bei $data->{weather}->{current_conditions}->{temp_c}->{data} Grad Zelsius\n");