require_once FS_ROOT . "/../../www/lib/util.php"; require_once FS_ROOT . "/../../www/lib/nzbinfo.php"; require_once FS_ROOT . "/../../www/lib/category.php"; require_once FS_ROOT . "/../../www/lib/releases.php"; if (!empty($argc)) { echo "\n\n***WARNING*** : This method of importing is deprecated - you should use /misc/update_scripts/import.php\n\n\n"; die; } $db = new DB(); $page = new AdminPage(); $nzb = new NZB(); $filestoprocess = array(); $browserpostednames = array(); $cat = new Category(); $releases = new Releases(); if ($page->isPostBack()) { $retval = ""; // // Via browser, build an array of all the nzb files uploaded into php /tmp location // if (isset($_FILES["uploadedfiles"])) { foreach ($_FILES["uploadedfiles"]["error"] as $key => $error) { if ($error == UPLOAD_ERR_OK) { $tmp_name = $_FILES["uploadedfiles"]["tmp_name"][$key]; $name = $_FILES["uploadedfiles"]["name"][$key]; $filestoprocess[] = $tmp_name; $browserpostednames[$tmp_name] = $name; } } } $groups = $db->query("SELECT ID, name FROM groups");
<?php require_once "config.php"; require_once WWW_DIR . "/lib/adminpage.php"; require_once WWW_DIR . "/lib/framework/db.php"; $db = new DB(); if (empty($argc)) { $page = new AdminPage(); } $filestoprocess = array(); $browserpostednames = array(); $viabrowser = false; if (!empty($argc) || $page->isPostBack()) { $retval = ""; // // Via browser, build an array of all the nzb files uploaded into php /tmp location // if (isset($_FILES["uploadedfiles"])) { foreach ($_FILES["uploadedfiles"]["error"] as $key => $error) { if ($error == UPLOAD_ERR_OK) { $tmp_name = $_FILES["uploadedfiles"]["tmp_name"][$key]; $name = $_FILES["uploadedfiles"]["name"][$key]; $filestoprocess[] = $tmp_name; $browserpostednames[$tmp_name] = $name; $viabrowser = true; } } } if (!empty($argc)) { $strTerminator = "\n"; $path = $argv[1];