diff options
| author | natec <natec@users.sourceforge.net> | 2001-03-17 00:46:26 +0000 |
|---|---|---|
| committer | natec <natec@users.sourceforge.net> | 2001-03-17 00:46:26 +0000 |
| commit | 40f1f172a81232e910e09981116e58f45bb6b344 (patch) | |
| tree | c1e70a3cb88d1fb8a8675db7ba3cb5b6942a4795 /phpBB/index.php | |
| parent | b1ce902c02c90e58dc54e52f90946937f7b569e0 (diff) | |
| download | forums-40f1f172a81232e910e09981116e58f45bb6b344.tar forums-40f1f172a81232e910e09981116e58f45bb6b344.tar.gz forums-40f1f172a81232e910e09981116e58f45bb6b344.tar.bz2 forums-40f1f172a81232e910e09981116e58f45bb6b344.tar.xz forums-40f1f172a81232e910e09981116e58f45bb6b344.zip | |
New template system. Lots of merging conflicts, so let nate know if he broke stuff.
git-svn-id: file:///svn/phpbb/trunk@105 89ea8834-ac86-4346-8a33-228a782c2dd0
Diffstat (limited to 'phpBB/index.php')
| -rw-r--r-- | phpBB/index.php | 19 |
1 files changed, 3 insertions, 16 deletions
diff --git a/phpBB/index.php b/phpBB/index.php index e41dcdeb35..3479835749 100644 --- a/phpBB/index.php +++ b/phpBB/index.php @@ -41,9 +41,6 @@ if(empty($viewcat)) include('includes/page_header.'.$phpEx); -$template->set_block("body", "catrow", "cats"); -$template->set_block("catrow", "forumrow", "forums"); - $sql = "SELECT c.* FROM ".CATEGORIES_TABLE." c, ".FORUMS_TABLE." f WHERE f.cat_id=c.cat_id @@ -99,12 +96,10 @@ if($total_categories) for($i = 0; $i < $total_categories; $i++) { - $template->set_var(array("CAT_ID" => $category_rows[$i]["cat_id"], + $template->assign_block_vars("catrow", array("CAT_ID" => $category_rows[$i]["cat_id"], "PHP_SELF" => $PHP_SELF, "CAT_DESC" => stripslashes($category_rows[$i]["cat_title"]))); - $template->parse("cats", "catrow", true); - $created_line = false; for($j = 0; $j < $total_forums; $j++) { @@ -152,7 +147,7 @@ if($total_categories) $moderators_links .= "<a href=\"profile.$phpEx?mode=viewprofile&user_id=".$forum_mods["forum_".$forum_rows[$j]["forum_id"]."_id"][$mods]."\">".$forum_mods["forum_".$forum_rows[$j]["forum_id"]."_name"][$mods]."</a>"; } - $template->set_var(array("FOLDER" => $folder_image, + $template->assign_block_vars("catrow.forumrow", array("FOLDER" => $folder_image, "FORUM_NAME" => stripslashes($forum_rows[$j]["forum_name"]), "FORUM_ID" => $forum_rows[$j]["forum_id"], "FORUM_DESC" => stripslashes($forum_rows[$j]["forum_desc"]), @@ -163,16 +158,8 @@ if($total_categories) "LAST_POST" => $last_post, "MODERATORS" => $moderators_links)); - $template->parse("forums", "forumrow", true); - - $created_line = true; } } - if($created_line) - { - $template->parse("cats", "forums", true); - $template->set_var("forums", ""); - } } // for ... categories @@ -181,7 +168,7 @@ else { error_die($db, GENERAL_ERROR, "There are no Categories or Foums on this board."); } -$template->pparse("output", "body"); +$template->pparse("body"); include('includes/page_tail.'.$phpEx); ?> |
