HELP! HELP! HELP! HELP!
I can't find a good CGI tutorial on mkdir's
The ones I do find only show part of the code like:
"mkdir($dir,0777)"
THEY DON' SHOW what's before this (how to query it) or after the code (HOW TO finish the execution).
I use PHP but the SAFE MODE is on so It's not working right.
I downloaded CGI programs that mkdir's on my server but I can't under stand the code.
Here is what I came up with to pars my own form query >>>>
########################################################
$QueryString = $ENV{ 'QUERY_STRING' } ;
@NameValuePairs = split (/&/, $QueryString, 1);
$parent_dir = "/home/user/public_html/folder/";
foreach $NameValue (@NameValuePairs)
{
($Name, $Value) = split (/=/, $NameValue);
$Value =~ tr/+/ /;
mkdir($parent_dir$Value,0777) || die "Cannot mkdir newdir: $!";
}
########################################################
Can you help me out ser with a complete sample of a query to make a directory?
Thanks!
AlexMcleaniii@yahoo.com
I can't find a good CGI tutorial on mkdir's
The ones I do find only show part of the code like:
"mkdir($dir,0777)"
THEY DON' SHOW what's before this (how to query it) or after the code (HOW TO finish the execution).
I use PHP but the SAFE MODE is on so It's not working right.
I downloaded CGI programs that mkdir's on my server but I can't under stand the code.
Here is what I came up with to pars my own form query >>>>
########################################################
$QueryString = $ENV{ 'QUERY_STRING' } ;
@NameValuePairs = split (/&/, $QueryString, 1);
$parent_dir = "/home/user/public_html/folder/";
foreach $NameValue (@NameValuePairs)
{
($Name, $Value) = split (/=/, $NameValue);
$Value =~ tr/+/ /;
mkdir($parent_dir$Value,0777) || die "Cannot mkdir newdir: $!";
}
########################################################
Can you help me out ser with a complete sample of a query to make a directory?
Thanks!
AlexMcleaniii@yahoo.com