thanks Phranque, that didn't seem to help but its possible I didn't change the correct file? There are two files for this script imagemagick.cgi and imagemagick.pl
Maybe if I show the first part of the code for imagemagick.pl it would help...
############################################################
sub CreateThumbnail{
use Image::Magick;;
my($final_thumb, $thumb, $t_width, $t_height);
my ($file, $width, $height) = @_;
#$width = $CONFIG{media_width} unless $width;
#$height = $CONFIG{media_height} unless $height;
$width = $CONFIG{media_width};
$height = $CONFIG{media_height};
($name, $ext) = &NameAndExt($file);
$path = &ParentDirectory($file);
$image = new Image::Magick;
$image->Read($file);
($orwidth,$orheight)=$image->Get('width','height');
if ($orwidth*$height>$orheight*$width)
{
and this is first part of the code for imagemagick.cgi
#!/usr/bin/
use Image::Magick;
###########################################################################
# imagemagick
###########################################################################
############################################################
eval {
($0=~ m,(.*)/[^/]+,) && unshift (@INC, "$1");
($0=~ m,(.*)\\[^\\]+,) && unshift (@INC, "$1");
require "config.pl";
unshift(@INC, $CONFIG{script_path});
unshift(@INC, "$CONFIG{script_path}/scripts");
require "database.pl";
require "default_config.pl";
require "imagemagick.pl";
require "html.pl";
require "library.pl";
require "mojoscripts.pl";
require 'new_database.pl';
use CGI;
use CGI::Carp qw(fatalsToBrowser);
&main;
};
if ($@) {
print "content-type:text/html\n\n";
print "Error Including configuration file, Reason: $@";
exit;
}