http://www.perlmonks.org?node_id=439680


in reply to mod_perl and image::size

Perhaps it is a file permissions issue. Make sure that the file is readable by the web server.

Another thing that could be happening is that you are using a relative path to specify the file location, and the script running under mod_perl might not be running from with the same current directory as the old script was. Try using chdir() or specifying the full path to the file to see if that helps.

The imgsize function returns 3 things when an error occurs. The results are (undef, undef, "ERRORMESSAGE"). Check that error message to see if/what error is occuring.

my($w, $h, $err) = imgsize($file); die $err if ($err);

These are the only things I can think of off the top of my head. It will be easier for people to help you if you post some code.

Brad