Svenska tecken med Perl modul URI::GoogleChart

#!/usr/bin/perl
use strict;
use warnings;

BEGIN {
    my $base_module_dir = ( getpwuid($>) )[7] . '/perl/';
    unshift @INC, map { $base_module_dir . $_ } @INC;
}

use CGI qw(:standard);
use URI::GoogleChart;
use encoding 'utf8';

print header;

print start_html(-title=>'Perl modul URI::GoogleChart');

my $u = URI::GoogleChart->new("pie-3d", 350, 100,
    data => [60, 40],
    label => ["Hålla mun", "och hacka!"],
) or die $!;

print "<img src=\"$u\">";

print end_html;

This entry was posted in Uncategorized. Bookmark the permalink.

Leave a Reply

Your email address will not be published. Required fields are marked *

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>