From d9cb4522bd0f445eef49316a5c9dd798e2803754 Mon Sep 17 00:00:00 2001 From: Dries Buytaert Date: Mon, 15 Sep 2003 15:58:20 +0000 Subject: - Book module improvements. This commit changes the behavior of the "view" hook. See mailing list for details; search for a mail with the subject: '[IMPORTANT] behavior of "view" hook changed'. Modified patch from Nick. --- modules/blog.module | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) (limited to 'modules/blog.module') diff --git a/modules/blog.module b/modules/blog.module index dcae01074..b3fb6ca8e 100644 --- a/modules/blog.module +++ b/modules/blog.module @@ -128,7 +128,7 @@ function blog_page_user($uid) { $trail[] = l(t("Home"), NULL); $trail[] = l(t("Blogs"), "blog"); $trail[] = t("%name's blog", array("%name" => $account->name)); - theme("path", $trail, $trail); + theme("breadcrumb", $trail); $result = pager_query("SELECT nid FROM {node} WHERE type = 'blog' AND uid = '$account->uid' AND status = 1 ORDER BY nid DESC", variable_get("default_nodes_main", 10)); while ($node = db_fetch_object($result)) { @@ -144,7 +144,7 @@ function blog_page_last() { // Breadcrumb navigation: $trail[] = l(t("Home"), NULL); $trail[] = t("Blogs"); - theme("path", $trail, $trail); + theme("breadcrumb", $trail); $result = pager_query("SELECT nid FROM {node} WHERE type = 'blog' AND status = 1 ORDER BY nid DESC", variable_get("default_nodes_main", 10)); @@ -232,13 +232,14 @@ function blog_page() { function blog_view($node, $main = 0) { if ($main == 0) { // Breadcrumb navigation: - $trail[] = l(t("Home"), NULL); - $trail[] = l(t("%name's blog", array("%name" => $node->name)), "blog/$node->uid"); - - theme("path", $trail, $trail); + $node->trail[] = l(t("Home"), NULL); + $node->trail[] = l(t("%name's blog", array("%name" => $node->name)), "blog/$node->uid"); } - theme("node", $node, $main); + $node->teaser = check_output($node->teaser); + $node->body = check_output($node->body); + + return $node; } function blog_link($type, $node = 0, $main) { -- cgit v1.2.3