<?php if (isset($show_aux_page)) { $aux_page = auxpgGetAuxPage($show_aux_page); if ($aux_page) { $smarty->assign("page_body", $aux_page["aux_page_text"]); $smarty->assign("aux_page_name", $aux_page["aux_page_name"]); $smarty->assign("show_aux_page", $aux_page["aux_page_ID"]); $smarty->assign("main_content_template", "show_aux_page.tpl"); } else { header("HTTP/1.0 404 Not Found"); header("HTTP/1.1 404 Not Found"); header("Status: 404 Not Found"); die(ERROR_404_HTML); } }
Redirect(ADMIN_FILE . "?dpt=custord&sub=aux_pages"); } $smarty->assign("add_new", 1); } else { if (isset($_GET["edit"])) { if (isset($_POST["save"])) { if (CONF_BACKEND_SAFEMODE) { Redirect(ADMIN_FILE . "?dpt=custord&sub=aux_pages&safemode=yes&edit=" . $_GET["edit"]); } $aux_page_text_type = 0; if (isset($_POST["aux_page_text_type"])) { $aux_page_text_type = 1; } auxpgUpdateAuxPage($_GET["edit"], $_POST["aux_page_name"], $_POST["aux_page_text"], $aux_page_text_type, $_POST["meta_keywords"], $_POST["meta_description"], $_POST["aux_page_title"]); Redirect(ADMIN_FILE . "?dpt=custord&sub=aux_pages"); } $aux_page = auxpgGetAuxPage($_GET["edit"]); if ($aux_page["aux_page_text_type"] == 1) { $aux_page["aux_page_text"] = html_spchars($aux_page["aux_page_text"]); } $smarty->assign("aux_page", $aux_page); $smarty->assign("edit", 1); } else { $aux_pages = auxpgGetAllPageAttributes(); $smarty->assign("aux_pages", $aux_pages); } } //set sub-department template $smarty->assign("admin_sub_dpt", "custord_aux_pages.tpl"); } }