exit;\r
} else if (is_dir($current_path.$pathext.$file)) {\r
// error: cannot edit folder\r
- debug($current_path.$pathext.$file);exit;\r
$msg->addError('BAD_FILE_TYPE');\r
header('Location: index.php?pathext='.$pathext.SEP.'framed='.$framed.SEP.'popup='.$popup.SEP.'_course_id='.$_course_id);\r
exit;\r
//check if this is a test import
if ($name == 'schema'){
if (trim($my_data)=='IMS Question and Test Interoperability'){
- $msg->addError('IMPORT_FAILED');debug('1');exit;
+ $msg->addError('IMPORT_FAILED');
}
$content_type = trim($my_data);
}
$archive = new PclZip($_FILES['file']['tmp_name']);
if ($archive->extract( PCLZIP_OPT_PATH, $import_path,
PCLZIP_CB_PRE_EXTRACT, 'preImportCallBack') == 0) {
- $msg->addError('IMPORT_FAILED');debug('2');exit;
+ $msg->addError('IMPORT_FAILED');
echo 'Error : '.$archive->errorInfo(true);
clr_dir($import_path);
header('Location: ../index.php');
if (@rename($import_path.$package_base_path, $course_dir.$package_base_name) === false) {
if (!$msg->containsErrors()) {
- $msg->addError('IMPORT_FAILED');debug('3');exit;
+ $msg->addError('IMPORT_FAILED');
}
}
//check if there are still resources missing
// debug($_base_path.$this->current_page);debug($page);
if ($_base_path.$this->current_page != $page['url'])
{
-// debug('here');exit;
header('Location: '.$page['url']);
// reset current_page after re-direction