admin) { // throw new Exception("@todo ACCESS DENIED"); // } $template = new View("local_import_admin.html"); $paths = unserialize(module::get_var("local_import", "authorized_paths")); if (!empty($paths)) { $template->dir_list = new View("local_import_dir_list.html"); $template->dir_list->paths = array_keys($paths); } else { $template->dir_list = ""; } $template->add_form = self::get_admin_form()->render(); return $template; } public static function get_admin_form() { $form = new Forge("admin/local_import/add_path", "", "post", array("id" => "gLocalImportAdminForm")); $form->input("path")->label(true); $form->submit(_("Add")); return $form; } }