in reply to Re^4: $cgi->param() values are not updated instantly when read in a subroutine
in thread $cgi->param() values are not updated instantly when read in a subroutine
due to cgi-bin, I'll assume you're running under mod_cgi
Although, seeing how your program seems to misbehave, that probably isn't the case.
And there are no warnings in the server logs??
Try this
#!/usr/bin/perl -w -- use strict; use warnings; use utf8; #this perl-file is written in utf-8 use CGI; use Data::Dumper; #zum debuggen Main(@ARGV); exit(0); sub Main { binmode STDOUT, ":encoding(utf8)"; my $cgi = CGI->new; $cgi->charset('UTF-8'); # Content-Type: text/html; charset=UTF-8 ## AND <meta http-equiv="Content-Type" content="text/html; charset=ut +f-8" /> print $cgi->header(); # Write HTTP header print $cgi->start_html, $cgi->b(rand time, ' ', scalar gmtime), $cgi->start_form, $cgi->textfield('creators_name'), $cgi->submit, $cgi->end_form, '<table border="1" width="%100"><tr><td>', $cgi->Dump, '</td><td><div style="white-space: pre-wrap; overflow: scroll;">', $cgi->escapeHTML( Dumper( $cgi ) ), '</div></td></tr></table>', CGI->new( \%ENV )->Dump, $cgi->end_html; }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^6: $cgi->param() values are not updated instantly when read in a subroutine
by Lukas (Initiate) on Mar 09, 2011 at 16:59 UTC | |
by ikegami (Patriarch) on Mar 09, 2011 at 17:14 UTC | |
by Anonymous Monk on Mar 09, 2011 at 18:55 UTC |