$error_flag = 1; } $fileid = $file->id; $filepath = $file->path; $filename = $file->name; // // if(!$file->img_to_small('sm_' . $f_name, array('width' => 100, 'height' => 100))) { // $alert[3] = "Невозможно уменьшить изображение"; // $error_flag = 1; // } } if (!$fileid) { $alert[3] = 'Необходимо загрузить файл.'; } if (!isset($alert)) { list($e, $errs) = articles::AddArticle($uid, $title, $short, $msgtext, $fileid); if ($errs) { $alert[0] = $errs; } } // var_dump($alert); if (!isset($alert)) { header('Location: ./?page=unpublished'); exit; } } break; case 'view': if (!$id) { header('Location: /404.php'); exit;