Okay So here’s my code that right now functions
[code=php]if ((isset($_POST[“MM_insert”])) && ($_POST[“MM_insert”] == “formInsertCollection”)) {
$insertSQL = sprintf(“INSERT INTO jmsgallery_collections (name, `description`, `path`) VALUES (%s, %s, %s)”,
GetSQLValueString($_POST[‘name’], “text”),
GetSQLValueString($_POST[‘description’], “text”),
GetSQLValueString($_POST[‘path’], “text”));
mkdir(“../gallery/success”, 0700);
What it does is does the update + creates a folder named success. I used the name success just to test out my idea, ’cause I wasn’t quite sure where to put the mkdir.
Now this is what I really need to do. I need to pull that path and replace success with it. So I tried this:
[code=php]if ((isset($_POST[“MM_insert”])) && ($_POST[“MM_insert”] == “formInsertCollection”)) {
$insertSQL = sprintf(“INSERT INTO jmsgallery_collections (name, `description`, `path`) VALUES (%s, %s, %s)”,
GetSQLValueString($_POST[‘name’], “text”),
GetSQLValueString($_POST[‘description’], “text”),
GetSQLValueString($_POST[‘path’], “text”));
mkdir(“../gallery/”$_POST[‘description’]””, 0700);
But, I’m not entirely sure how to format it because it keeps coming up with this error: [22-Feb-2008 16:21:31] PHP Parse error: parse error, unexpected T_VARIABLE in /TEST/JMS_Software/JMSGallery/admin/functions/photos-collections-new.php on line 42. Line 42 is the mkdir.
Any ideas on how to fix my idea? Or if I’m approaching it the completely wrong way? lol