Is there a simple way to use a text box in a form to check if a directory exists and if it doesn’t create it? If it does then store file through a upload field on same form. If it doesn’t create it and store files to it.
I’m using a mysql DB for storing data from form.
part of the Process.php file
$query = "INSERT into `".$db_table."` (Venue_Name,Gallery_Image_1,Gallery_Image_2,Gallery_Image_3,Gallery_Image_4,Gallery_Image_5,Gallery_Image_6,Gallery_Image_7,Gallery_Image_8,Gallery_Image_9,Gallery_Image_10) VALUES ('" . $_POST['Venue_Name'] . "','" . $_POST['Gallery_Image_1'] . "','" . $_POST['Gallery_Image_2'] . "','" . $_POST['Gallery_Image_3'] . "','" . $_POST['Gallery_Image_4'] . "','" . $_POST['Gallery_Image_5'] . "','" . $_POST['Gallery_Image_6'] . "','" . $_POST['Gallery_Image_7'] . "','" . $_POST['Gallery_Image_8'] . "','" . $_POST['Gallery_Image_9'] . "','" . $_POST['Gallery_Image_10'] . "')";
mysql_query($query);
I have another form that the Venue_Name is created from by user.