<?php define("__ADMIN__", true); try { $links = new Links(); $linksCat = new LinkCat(); $Users = new Users(); $links->setId($vars['id']); $Users->BuildData(); $links->BuildData(); $linksCat->BuildData(); $smarty->assign(array("load" => "links/form/link_edit.tpl", "loadindex" => "links/view/link_index.tpl", "user_list" => $Users->getRecords(), "link_cat_list" => $linksCat->getIndex(), "linkCat_index" => $linksCat->getIndex(), "records" => $links->getRecords())); $smarty->display('admin/body/index.tpl'); } catch (Exception $e) { print "Exception: " . $e->getMessage(); }
<?php define("__ADMIN__", true); require_once "../../public_html/config.php"; try { $Archive = new Archive(); $Archive->setPostId($_GET['postid']); if (!$_COOKIE['login']) { $Archive->setPublic(1); } $links = new Links(); $links->setFileName("/links.php"); $links->setPage($vars['page'], "page"); $links->setCatId($vars['cat']); $links->setId($vars['id']); $linksCat = new LinkCat(); $linksCat->setFileName("/links.php"); $linksCat->setPage($vars['page'], "page"); $linksCat->setId($vars['cat']); $Archive->BuildData(); $links->BuildData(); $linksCat->BuildData(); if ($vars['id']) { header("location: {$links->getRecords()}"); } else { if ($vars['cat']) { $title = "Links : ( {$linksCat->getTitle()} ) Page : " . (1 + $links->getPage()) . " of " . $links->getnumOfRecords(); $loadFile = "links.tpl"; $records = $links->getRecords(); $pageList = $links->getCountDisplay(); } else {
<?php try { $links = new Links(); $links->setFileName("/Admin_Links"); $links->setPage($vars['page'], "page"); $links->setCatId($vars['cat']); $links->setId($vars['id']); $linksCat = new LinkCat(); $links->BuildData(); $linksCat->BuildData(); if ($vars['cat']) { $title = "Links : ( {$linksCat->getTitle($links->getCatId())} ) Page : " . (1 + $links->getPage()) . " of " . $links->getnumOfRecords(); } else { $title = "Link Categories : Page : " . (1 + $linksCat->getPage()) . " of " . $linksCat->getnumOfRecords(); } $smarty->assign(array("page_name" => $title, "load" => "links/view/links.tpl", "loadindex" => "links/view/link_index.tpl", "linkCat_index" => $linksCat->getIndex(), "records" => $links->getRecords(), "page_list" => $links->getCountDisplay())); $smarty->display('admin/body/index.tpl'); } catch (Exception $e) { print "Exception: " . $e->getMessage(); }
<?php if ($vars['cat'] && !isal_num($vars['cat'])) { header("Location: /public/LinkCategories"); } try { $Archive = new Archive(); $links = new Links(); $links->setFileName("/LinkCategories"); $links->setPage($vars['page'], "page"); $links->setCatId($vars['cat']); $links->setId($vars['url']); if (!$_SESSION['login']) { $Archive->setPublic(1); } $linksCat = new LinkCat(); $linksCat->setFileName("/LinkCategories"); if (!$vars['cat']) { $linksCat->setPage($vars['page'], "page"); } $linksCat->setId($vars['cat']); $Archive->BuildData(); $links->BuildData(); $linksCat->BuildData(); if ($vars['url']) { if (is_array($row = $links->getRecords())) { foreach ($row as $info) { $url = $info['link_url']; } header("location: {$url}"); }
<?php define("__ADMIN__", true); try { $linksCat = new LinkCat(); $Users = new Users(); $linksCat->BuildData(); $Users->BuildData(); $smarty->assign(array("page_name" => "Link : Category : New", "load" => "links/form/link_categories_new.tpl", "loadindex" => "links/view/link_index.tpl", "user_list" => $Users->getRecords(), "linkCat_index" => $linksCat->getIndex())); $smarty->display('admin/body/index.tpl'); } catch (Exception $e) { print "Exception: " . $e->getMessage(); }
<?php try { $linksCat = new LinkCat(); $Users = new Users(); $linksCat->setId($vars['id']); $linksCat->BuildData(); $Users->BuildData(); $smarty->assign(array("page_name" => "Link : Category : Edit", "load" => "links/form/link_categories_edit.tpl", "loadindex" => "links/view/link_index.tpl", "user_list" => $Users->getRecords(), "linkCat_index" => $linksCat->getIndex(), "records" => $linksCat->getRecords())); $smarty->display('admin/body/index.tpl'); } catch (Exception $e) { print "Exception: " . $e->getMessage(); }