En lille fejl fra mig
den skal sættes ind i denne..!
Around line 63 is the variable $Data. You will have to set this variable to the absolute path to the directory you created.
if(($ENV{\'QUERY_STRING\'} =~ /^debug/) && !$no_debug) {
print \"Pragma: no-cache\\nContent-type: text/html\\n\\n\";
print \"<TITLE>PSUpload Demonstration Upload Program - Debug Mode</TITLE></HEAD><BODY BGCOLOR=\\\"#ffffff\\\" TEXT=\\\"#330066\\\" LINK=\\\"#336666\\\" ALINK=\\\"#336666\\\" VLINK=\\\"#336666\\\" BGCOLOR=\\\"#FFFFFF\\\"><FONT SIZE=\\\"2\\\" FACE=\\\"verdana, arial, helvetica\\\">\\n\";
print \"<CENTER><B><H2>Charity Ware\'s PSUpload Program</H2></B><BR><BR><TABLE BORDER=0><TR><TD COLSPAN=2><FONT SIZE=\\\"2\\\" FACE=\\\"verdana, arial, helvetica\\\">\\n\";
print \"<DL><DT><B>Your web root directory appears to be located at:</B><DD>$ENV{\'DOCUMENT_ROOT\'}<BR><BR><DT><B>You specified directory for storing the uploads is:</B><DD>$Data<BR><BR><DT><B>Your specified directory...</B><DD>\\n\";
if(-d $Data) {
print \"...appears to be a valid directory.<BR><BR>Make sure this \\$Data directory is CHMOD 777.\\n\";
} else {
print \"...does not appear to be a valid directory.<BR><BR>\\n\";
unless($Data =~ /^$ENV{\'DOCUMENT_ROOT\'}/) {
print \"The value you specified in the \\$Data variable is incorrect. Please<BR>correct your \\$Data variable and run debug again.<BR><BR>\\n\";
}
}
if($Data =~ /\\/$/) {
print \"<FONT COLOR=\\\"#FF0000\\\">NOTE: Your variable \\$Data ends with a trailing slash. Please<BR>remove this trailing slash, upload the program again<BR>and run debug once more to see if you have a valid directory.</FONT><BR><BR>\\n\";
}
print \"</DL><BR><BR></FONT></TD></TR><TR><TD WIDTH=\\\"50%\\\" VALIGN=\\\"TOP\\\"><FONT SIZE=\\\"2\\\" FACE=\\\"verdana, arial, helvetica\\\"><B>OS:</B><BR>$^O<BR><BR><B>Perl:</B><BR>$]</FONT></TD><TD VALIGN=\\\"TOP\\\"><FONT SIZE=\\\"2\\\" FACE=\\\"verdana, arial, helvetica\\\"><B>Installed:</B><BR>\"; my @inst = split(/\\//, $ENV{\'SERVER_SOFTWARE\'}); print join(\"<BR>\", @inst); print\"</FONT></TD></TR></TABLE><BR><BR><BR><BR><A HREF=\\\"
http://www.charityware.ws/\\\">© 2001, Jim Melanson</A></CENTER><BR><BR></FONT></BODY></HTML>\\n\";
} else {
use CGI;