YourDirector
04-11-2012, 10:50 AM
Hey all,
I'm currently building a website where users can create pages which pictures can eventually be uploaded to. I want it so when a new page is created a folder is made on the server specific to that event which will then contain all photo's for that event.
This is what I'm currently working with but for some reason just isn't working:
Attempt style 1:
$newfolder = mkdir("../imagehub/events/".$evt.$name, 0777);
Attempt style 2:
$newfolder = mkdir("../imagehub/events/$evt$name", 0777);
Attempt style 3:
if(!mkdir("../imagehub/events/$evt$name"){
echo "File not created";
}else{
echo "File Created";
};
Attempt style 4:
$newfolder = "../imagehub/events/".$evt.$name;
mkdir($newfolder, 0777);
I presume I'm going wrong somewhere but a little nudge in the right direction would be much appreciated! :)
I'm currently building a website where users can create pages which pictures can eventually be uploaded to. I want it so when a new page is created a folder is made on the server specific to that event which will then contain all photo's for that event.
This is what I'm currently working with but for some reason just isn't working:
Attempt style 1:
$newfolder = mkdir("../imagehub/events/".$evt.$name, 0777);
Attempt style 2:
$newfolder = mkdir("../imagehub/events/$evt$name", 0777);
Attempt style 3:
if(!mkdir("../imagehub/events/$evt$name"){
echo "File not created";
}else{
echo "File Created";
};
Attempt style 4:
$newfolder = "../imagehub/events/".$evt.$name;
mkdir($newfolder, 0777);
I presume I'm going wrong somewhere but a little nudge in the right direction would be much appreciated! :)