Submissions are closed.
'; printFooter(); exit; } // Get topics $topq = "SELECT * FROM `" . OCC_TABLE_TOPIC . "`"; $topr = ocsql_query($topq) or err('unable to retrieve topics'); if (($tnum = mysql_num_rows($topr)) < 1) { warn('We are still waiting for the Program Chair to finalize the list of topics before opening up for submissions. Please check back later.'); } else { $half = ceil($tnum / 2); $topicAR = array(); while ($topl = mysql_fetch_assoc($topr)) { $topicAR[$topl['topicid']] = $topl['topicname']; } } // Check whether this is a submission if (isset($_POST['submit']) && ($_POST['submit'] == "Make Submission")) { $err = ''; $errInc = ''; // Check title if (!preg_match("/\w+/",$_POST['title'])) { $err .= "Please check the following:' . $err . $errInc . '
This submission appears to already have been made; please check your email for a confirmation. '; if ($OC_statusAR['OC_edit_open']) { print 'You may review or edit the submission here. '; } print 'Please contact the Chair with any questions.
'; printFooter(); exit; } $backupMsg = ''; // add paper $q = "INSERT INTO `" . OCC_TABLE_PAPER . "` (`password`,`title`,`student`,`contactid`,`contactemail`,`contactphone`,`submissiondate`,`lastupdate`,`format`,`otherauthors`,`keywords`,`comments`,`abstract`) VALUES (" . "'" . hashPassword(stripslashes($_POST['password1'])) . "'," . "'" . safeSQLstr($_POST['title']) . "'," . "'" . $_POST['student'] . "'," . "'" . $_POST['contact'] . "'," . "'" . safeSQLstr(oc_strtolower($_POST['contactaltemail'])) . "'," . "'" . safeSQLstr($_POST['contactphone']) . "'," . "'" . date("Y-m-d") . "'," . "'" . date("Y-m-d") . "'," . "NULL," . "'" . safeSQLstr($_POST['otherauthors']) . "',". "'" . safeSQLstr($_POST['keywords']) . "',". "'" . safeSQLstr($_POST['comments']) . "',". "'" . safeSQLstr($_POST['abstract']) . "'". ")"; $r = ocsql_query($q) or err("unable to process submission ".mysql_errno()); $backupMsg .= "$q\n\n"; // get paper ID $pid = mysql_insert_id() or err("unable to get submission id ".mysql_errno()); // add authors for ($i=1;$i<=5;$i++) { if (!empty($_POST["name_last$i"])) { $q = "INSERT INTO " . OCC_TABLE_AUTHOR . " (paperid,position,name_last,name_first,organization,country,email) VALUES (". "'$pid',". "'$i',". "'".safeSQLstr($_POST["name_last$i"])."',". "'".safeSQLstr($_POST["name_first$i"])."',". "'".safeSQLstr($_POST["org$i"])."',". "'".safeSQLstr($_POST["country$i"])."',". "'".safeSQLstr($_POST["email$i"])."'". ")"; $r = ocsql_query($q) or err("unable to add one or more authors, but submission added. Please edit submission. ".mysql_errno()); $backupMsg .= "$q\n\n"; } } // add topic(s) foreach ($_POST['topic'] as $t) { if (is_numeric($t)) { $q = "INSERT INTO " . OCC_TABLE_PAPERTOPIC . " (paperid,topicid) VALUES ($pid,$t)"; $r = ocsql_query($q) or err("unable to add paper topic, but paper and authors added ".mysql_errno()); $backupMsg .= "$q\n\n"; } else { err("invalid submission topic - ..$t.."); } } if (!empty($OC_configAR['OC_subBackupEmail'])) { sendEmail($OC_configAR['OC_subBackupEmail'], "Submission ID $pid SQL", $backupMsg); } if (oc_hookSet('author-submit-save')) { foreach ($GLOBALS['OC_hooksAR']['author-submit-save'] as $hook) { require_once $hook; } } $confirmmsg = ' Submission ID: '.$pid.' Title: '.stripslashes($_POST['title']).' '; if ($OC_configAR['OC_trackStudent'] == 1) { $confirmmsg .= 'Student: '.$_POST['student']; } for ($i=1;$i<=5;$i++) { $confirmmsg .= ' Author ' . $i; if ($i == $_POST['contact']) { $confirmmsg .= " (CONTACT AUTHOR)"; } $confirmmsg .= ' Name: '.stripslashes($_POST["name_first$i"] . " " . $_POST["name_last$i"]).' Org: '.stripslashes($_POST['org'.$i]).' Country: '.$_POST['country'.$i].' Email:'.$_POST['email'.$i]; } $confirmmsg .= ' Other Authors: '.stripslashes($_POST['otherauthors']).' Contact Alt Email: '.$_POST['contactaltemail'].' Contact Phone: '.$_POST['contactphone'].' Keywords: '.stripslashes($_POST['keywords']).' Abstract: '.stripslashes($_POST['abstract']).' Comments: '.stripslashes($_POST['comments']) . ' '; if (oc_hookSet('author-submit-confirm')) { foreach ($GLOBALS['OC_hooksAR']['author-submit-confirm'] as $hook) { require_once $hook; } } // confirm it print ' Thank you for your submission. Your submission ID number is ' . $pid . '. Please write this number down and include it in any communications with the conference committee.Below is the information submitted. We have also emailed a copy to the contact author. If you notice any problems or do not receive the email within 24 hours, please contact the Program Chair.
' . safeHTMLstr($confirmmsg) . ''; $confirmmsg = "Thank you for your submission to " . $OC_configAR['OC_confName'] . ". Below is a copy of the information submitted for your records.\n\n" . $confirmmsg; sendEmail($contactemail, "Submission ID $pid", $confirmmsg, $OC_configAR['OC_notifyAuthorSubmit']); printFooter(); exit; } // else no errors } // Print Form print ' ' . $OC_configAR['OC_paperSubNote'] . '
'; printFooter(); ?>