I am trying to create a new folder in another folder, using the name for it from the input.
<form>
Album name <input type="text" name="album_name">
<input type="submit">
</form>
<?php
if(isset($_POST['album_name'])) {
$albumName = $_POST['album_name'];
$path = 'albums/' . $albumName;
if (!file_exists($albumName)) {
mkdir($path, 0777, true);
}
}else{
echo 'it is so saad';
}
?>
But the folder hasn't created. What is the problem? :(