' . oc_('Submission withdraw is not available.') . '

'; printFooter(); exit; } // Is this a post? if (isset($_POST['ocaction']) && ($_POST['ocaction'] == 'Withdraw Submission')) { // Check for paper ID & password if (! isset($_POST['pid']) || ! preg_match("/^\d+$/", $_POST['pid']) || ! isset($_POST['pwd']) || empty($_POST['pwd']) ) { warn(oc_('Submission ID or password entered is incorrect')); printFooter(); exit; } $pq = "SELECT `" . OCC_TABLE_PAPER . "`.`title`, `" . OCC_TABLE_PAPER . "`.`password`, `" . OCC_TABLE_AUTHOR . "`.`email` FROM `" . OCC_TABLE_PAPER . "`, `" . OCC_TABLE_AUTHOR . "` WHERE `" . OCC_TABLE_PAPER . "`.`paperid`='" . $_POST['pid'] . "' AND `" . OCC_TABLE_PAPER . "`.`paperid`=`" . OCC_TABLE_AUTHOR . "`.`paperid` AND `" . OCC_TABLE_PAPER . "`.`contactid`=`" . OCC_TABLE_AUTHOR . "`.`position`"; $pr = ocsql_query($pq) or err("Unable to retrieve submission ".mysql_errno()); if (mysql_num_rows($pr) != 1) { warn(oc_('Submission ID or password entered is incorrect')); printFooter(); exit; } $pl = mysql_fetch_array($pr); if ((hashPassword($_POST['pwd'], $pl['password']) != $pl['password']) && (!OCC_CHAIR_PWD_TRUMPS || (hashPassword($_POST['pwd'], $OC_configAR['OC_chair_pwd']) != $OC_configAR['OC_chair_pwd']))) { warn(oc_('Submission ID or password entered is incorrect')); printFooter(); exit; } // Withdraw submission if (withdrawPaper($_POST['pid'], 'Author')) { deletePaper($_POST['pid']); print '

' . oc_('Your submission has been withdrawn. If this is not what you intended to do, please contact the Chair.') . '

'; // Notify via email $confirmmsg = oc_("The submission below has been widthdrawn at the author's request. If you did not intend to withdraw the submission, please contact the Chair.") . ' ' . oc_('Submission ID') . ': ' . $_POST['pid'] . ' ' . oc_('Title') . ': ' . $pl['title'] . ' '; sendEmail($pl['email'], sprintf(oc_('Submission Withdraw - ID %s'), $_POST['pid']), $confirmmsg, $OC_configAR['OC_notifyAuthorWithdraw']); } else { print '

' . oc_('We encountered a problem withdrawing your submission. Please contact the Chair.') . '

'; } printFooter(); exit; } // if submit // display sub id/password form print '
: ( ' . oc_('forgot ID?') . ' )
: ( ' . oc_('forgot password?') . ' )

'; printFooter(); exit; ?>