"print" sends its output to STDOUT whilst "die" (like "warn") sends to STDERR. In a CGI environment, STDOUT goes to the browser that requested the page, STDERR to Apache log file; so you can add $! to the print line like
print "Not able to create directory $!";
Rule One: "Do not act incautiously when confronting a little bald wrinkly smiling man."
In reply to Re: trapping system error
by psini
in thread trapping system error
by anu_1
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |