From e37f9866bf28a011cc2e884c7a5e2ea6e8508fc0 Mon Sep 17 00:00:00 2001 From: Kelly Rauchenberger Date: Sun, 7 Sep 2008 13:14:00 +0000 Subject: Series: Fixed up index.php Refs #53 --- series/core/trunk/includes/instadisc.php | 9 +++++++++ series/core/trunk/index.php | 3 ++- series/core/trunk/theme/index.tpl | 3 ++- 3 files changed, 13 insertions(+), 2 deletions(-) (limited to 'series') diff --git a/series/core/trunk/includes/instadisc.php b/series/core/trunk/includes/instadisc.php index b1b6ce5..3e0ff32 100644 --- a/series/core/trunk/includes/instadisc.php +++ b/series/core/trunk/includes/instadisc.php @@ -42,4 +42,13 @@ function instaDisc_getAllSubscriptions() return $getsubs3; } +function instaDisc_getConfig($name) +{ + $getconfig = "SELECT * FROM config WHERE name = \"" . mysql_real_escape_string($name) . "\""; + $getconfig2 = mysql_query($getconfig); + $getconfig3 = mysql_fetch_array($getconfig2); + + return $getconfig3['value']; +} + ?> diff --git a/series/core/trunk/index.php b/series/core/trunk/index.php index 7d3916c..9d8cb05 100644 --- a/series/core/trunk/index.php +++ b/series/core/trunk/index.php @@ -5,13 +5,14 @@ include('includes/instadisc.php'); $template = new FITemplate('index'); +$template->add('SITENAME', instaDisc_getConfig('siteName')); $subs = instaDisc_getAllSubscriptions(); foreach ($subs as $name => $value) { if ($value['personal'] == 'false') { - $template->adds_block('SUBSCRIPTION', array( 'IDENTITY' => $name, + $template->adds_block('SUBSCRIPTIONS', array( 'IDENTITY' => $value['identity'], 'TITLE' => $value['title'], 'CATEGORY' => $value['category'])); } diff --git a/series/core/trunk/theme/index.tpl b/series/core/trunk/theme/index.tpl index 6c22f3e..338f0cc 100644 --- a/series/core/trunk/theme/index.tpl +++ b/series/core/trunk/theme/index.tpl @@ -1,4 +1,5 @@ -

Subscriptions Available

+

+

Subscriptions Available