From db046504117867ebc2454d856f562bbe30bbe48b Mon Sep 17 00:00:00 2001 From: Dries Buytaert Date: Mon, 28 Apr 2003 21:36:43 +0000 Subject: - Added support for user registration guidelines. Patch by Al. Feature request #1109. --- modules/title.module | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'modules/title.module') diff --git a/modules/title.module b/modules/title.module index 686bfd66b..693a9361f 100644 --- a/modules/title.module +++ b/modules/title.module @@ -14,18 +14,18 @@ function title_page() { if (db_num_rows($result) == 0) { // No node with exact title found, try substring. $result = db_query("SELECT n.* FROM node n WHERE n.title LIKE '%". check_query($title). "%' AND n.status = 1 ORDER BY created DESC"); - } - if (db_num_rows($result) == 0 && module_exist("search")) { + } + if (db_num_rows($result) == 0 && module_exist("search")) { // still no matches ... return a full text search search_view($title); } - else if (db_num_rows($result) == 1) { + else if (db_num_rows($result) == 1) { $node = db_fetch_object($result); - + theme("header"); print node_show($node->nid, NULL); theme("footer"); - } + } else { $header = array(t("Type"), t("Title"), t("Author")); while ($node = db_fetch_object($result)) { @@ -34,8 +34,8 @@ function title_page() { $author = format_name($node); $rows[] = array(array("data" => $type, "class" => "type"), array("data" => $title, "class" => "content"), array("data" => $author, "class" => "author")); } - - $output = "
"; + + $output = "
"; $output .= table($header, $rows); $output .= "
"; @@ -73,6 +73,6 @@ function title_compose_tips() { if (variable_get("title_filter_link", 0)) { return array(t("You may quickly link to another node using this syntax: [node title|text]. This will generate a link labeled 'text' to the node with the title 'node title'. If you omit '|text', the label becomes 'node title'.")); } -} +} ?> -- cgit v1.2.3