aboutsummaryrefslogtreecommitdiffstats
path: root/web/nms-public.gathering.org/weathermap.pl
blob: 41aca391a0fae91e1a1c20e3f58e11f2c0bafe8f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#! /usr/bin/perl
use strict;
use warnings;
use CGI;
use File::Copy;

my $cgi = CGI->new;
my $img_filename = "/root/tgmanage/web/nms-public.gathering.org/weathermap.png";

# this must be done for windows
binmode STDOUT;
	
# flush headers
$|=1;
	
# print the image
print $cgi->header(-type=>'image/png; charset=utf-8', -refresh=>'10; weathermap.pl');
copy "$img_filename", \*STDOUT;