in reply to Re: YAUQ
in thread problems uploading to an HTTP site

strict doesn't apply to file handles but if you had warnings on, you might have seen something like Name "main::OUT" used only once: possible typo at ... or maybe even print() on unopened filehandle OUT at ....

Update: I see you did have warnings on but since this was a CGI script, those messages are probably in your web server's error log. You might want to use CGI::Carp qw(fatalsToBrowser warningsToBrowser); at least during development so that you'll see these messages.

--- print map { my ($m)=1<<hex($_)&11?' ':''; $m.=substr('AHJPacehklnorstu',hex($_),1) } split //,'2fde0abe76c36c914586c';

Replies are listed 'Best First'.
Re^3: YAUQ
by Aristotle (Chancellor) on Jan 15, 2003 at 07:50 UTC
    And remember that you have to manually force the warnings to be output by calling warningsToBrowser(1); - in the simplest case, just do it before the script exits, so you get a cumulative list of all the warnings as a neat list of HTML comments at the bottom of the CGI generated page.

    Makeshifts last the longest.

Re: Re: Re: YAUQ
by emilford (Friar) on Jan 15, 2003 at 12:55 UTC
    That makes sense. I will check my server's error log to see if there is any mention of this error.

    Having error messages printed to the browser would have saved me from posting my careless mistake. :) I'll start using CGI::Carp qw(fatalsToBrowser warningsToBrowser) to help check my code. Although I do recall compling this bit of code from the command line using perl -c upload.pl and it simply responded with perl syntax OK.

    Thanks