Hey guys, I'm trying to figure out why mkdir isn't working for me. I've got an HTML form sending info to my cgi program (written in perl) like this
Html part of the form is
<INPUT TYPE=text NAME=filedir>
the Cgi goes something like this
my $basedir = "c:/test"
use CGI;
my $reg = new CGI;
my $filedir = $reg->param("filedir"
;
mkdir ("$basedir/$filedir",0777);
and so on and so on.
My problem is, if in the text box I write something, I get the new directory like I'm supposed to. BUT... If i write
newdir/anotherdir
or
newdir\anotherdir
it doesnt work at all. it wont even create the first directory, let alond the directory withing that directory.
Any ideas anyone???
Html part of the form is
<INPUT TYPE=text NAME=filedir>
the Cgi goes something like this
my $basedir = "c:/test"
use CGI;
my $reg = new CGI;
my $filedir = $reg->param("filedir"
mkdir ("$basedir/$filedir",0777);
and so on and so on.
My problem is, if in the text box I write something, I get the new directory like I'm supposed to. BUT... If i write
newdir/anotherdir
or
newdir\anotherdir
it doesnt work at all. it wont even create the first directory, let alond the directory withing that directory.
Any ideas anyone???