From 716e58df8d4c4889bfaf574e231c0cc14479454f Mon Sep 17 00:00:00 2001 From: jhunkeler Date: Mon, 21 Dec 2009 04:59:17 +0000 Subject: Added page list ability, but need clarification on how we are accessing pages versus articles. git-svn-id: http://svn.3rd-infantry-division.org/testing/branches/Bayonet CMS v2@385 c5b2fb0a-d05d-0410-98c8-828840a80ff6 --- modules/page/index.php | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) (limited to 'modules/page/index.php') diff --git a/modules/page/index.php b/modules/page/index.php index e5ac25e..68dbb62 100644 --- a/modules/page/index.php +++ b/modules/page/index.php @@ -26,6 +26,38 @@ if(!defined("MODULE_FILE")) global $db; +/** + * List available pages. + * Only right now I don't know if the _pages table has been deprecated. + * I'm confused. -jhunk + */ +if(isset($_GET['list'])) +{ + if($_GET['list'] == "true") + { + $result = $db->Query("SELECT title, page_id FROM bayonet_articles"); + while(($row = $db->Fetch($result)) !== false) + { + $pages[] = $row; + } + mysql_free_result($result); + + OpenTable(); + echo "
Page Map
"; + echo "
"; + echo ""; + echo "
"; + CloseTable(); + + /* Kill module execution to prevent odd page results */ + return; + } +} if(!isset($_GET['id'])) { -- cgit