I have a script that registers users and i want to implement in it this function to make for each user a folder with the name they supply so i used

$user_folder = mkdir($_SERVER['HTTP_HOST'].'/user/'.$name, 0755);

$name is the name they supplyed in the form

so i get this "Warning: mkdir() [function.mkdir]: No such file or directory in /home/public_html/registration/index.php on line 139"
Why?

solve it, just my ftp program wasn't refreshing

ok it seems not to work so i added

$target = 'http://'.$_SERVER['HTTP_HOST'].'/user/'.$name;
if (!is_dir($target)) {
     mkdir($target, 0777);
}

and still doesn't work

Please mark as solved =)

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.