Added charset to HTTP header output.
This commit is contained in:
parent
7e72b0cd01
commit
56199acc2f
15 changed files with 19 additions and 21 deletions
12
perl/perl.pl
12
perl/perl.pl
|
|
@ -6,13 +6,11 @@ use warnings;
|
|||
use strict;
|
||||
use POSIX qw(strftime);
|
||||
|
||||
my $date = strftime "%m/%d/%Y", localtime;
|
||||
|
||||
print("Content-type: text/plain\n\n");
|
||||
print "Hello from Perl!\n\n";
|
||||
print $date;
|
||||
print "\n\n";
|
||||
|
||||
print("Content-type: text/plain; charset=utf-8\n\n");
|
||||
print("Hello from Perl!\n\n");
|
||||
print("print(strftime('%m/%d/%Y %Z', localtime));\n");
|
||||
print(strftime("%m/%d/%Y %Z", localtime));
|
||||
print("\n\n");
|
||||
print('my @i = (1..10); for(@i) { print("$_", "\n"); }');
|
||||
print("\n");
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue