diff options
Diffstat (limited to 'modules')
-rw-r--r-- | modules/book.module | 3 | ||||
-rw-r--r-- | modules/book/book.module | 3 | ||||
-rw-r--r-- | modules/forum.module | 20 | ||||
-rw-r--r-- | modules/forum/forum.module | 20 | ||||
-rw-r--r-- | modules/node.module | 2 | ||||
-rw-r--r-- | modules/node/node.module | 2 | ||||
-rw-r--r-- | modules/story.module | 4 | ||||
-rw-r--r-- | modules/story/story.module | 4 | ||||
-rw-r--r-- | modules/user.module | 7 | ||||
-rw-r--r-- | modules/user/user.module | 7 |
10 files changed, 34 insertions, 38 deletions
diff --git a/modules/book.module b/modules/book.module index e8f672cbf..85f70c7f6 100644 --- a/modules/book.module +++ b/modules/book.module @@ -411,7 +411,8 @@ function book_view($node, $main = 0) { // build the tree from bottom to top to have the book index in $level for navigation later $path = book_location($node); - $trail[] = l(t("Books"), "book"); + $trail[] = l(t("Home"), ""); + $trail[] = l(t("books"), "book"); foreach ($path as $level) { $trail[] = l($level->title, "node/view/$level->nid"); } diff --git a/modules/book/book.module b/modules/book/book.module index e8f672cbf..85f70c7f6 100644 --- a/modules/book/book.module +++ b/modules/book/book.module @@ -411,7 +411,8 @@ function book_view($node, $main = 0) { // build the tree from bottom to top to have the book index in $level for navigation later $path = book_location($node); - $trail[] = l(t("Books"), "book"); + $trail[] = l(t("Home"), ""); + $trail[] = l(t("books"), "book"); foreach ($path as $level) { $trail[] = l($level->title, "node/view/$level->nid"); } diff --git a/modules/forum.module b/modules/forum.module index 942874299..a8a05d1b8 100644 --- a/modules/forum.module +++ b/modules/forum.module @@ -455,32 +455,29 @@ function forum_page() { function forum_theme_display($forums, $topics, $parents, $tid, $sortby, $forum_per_page, $offset) { // forum list, topics list, topic browser and "add new topic" link - theme("header"); /* ** Breadcrumb navigation: */ - if ($tid) { - $trail[] = l(t("Forums"), "forum"); - } - else { - $trail[] = t("Forums"); - } + $trail[] = l(t("Home"), ""); + $trail[] = l(t("forums"), "forum"); if ($parents) { $parents = array_reverse($parents); foreach ($parents as $p) { - if ($tid != $p->tid) { - $trail[] = l($p->name, "forum/$p->tid"); + if ($p->tid == $tid) { + $title = $p->name; } else { - $trail[] = $p->name; + $trail[] = l(strtolower($p->name), "forum/$p->tid"); } } } $output = "<div id=\"forum\">"; + $output .= "<div class=\"path\">". implode($trail, " » ") ."</div>"; + $output .= "<div class=\"title\">$title</div>"; $output .= theme("forum_theme_list", $forums, $parents, $tid); if ($tid) { @@ -489,7 +486,8 @@ function forum_theme_display($forums, $topics, $parents, $tid, $sortby, $forum_p $output .= "</div>"; - theme("box", implode($trail, " » "), $output); + theme("header"); + theme("box", NULL, $output); theme("footer"); } diff --git a/modules/forum/forum.module b/modules/forum/forum.module index 942874299..a8a05d1b8 100644 --- a/modules/forum/forum.module +++ b/modules/forum/forum.module @@ -455,32 +455,29 @@ function forum_page() { function forum_theme_display($forums, $topics, $parents, $tid, $sortby, $forum_per_page, $offset) { // forum list, topics list, topic browser and "add new topic" link - theme("header"); /* ** Breadcrumb navigation: */ - if ($tid) { - $trail[] = l(t("Forums"), "forum"); - } - else { - $trail[] = t("Forums"); - } + $trail[] = l(t("Home"), ""); + $trail[] = l(t("forums"), "forum"); if ($parents) { $parents = array_reverse($parents); foreach ($parents as $p) { - if ($tid != $p->tid) { - $trail[] = l($p->name, "forum/$p->tid"); + if ($p->tid == $tid) { + $title = $p->name; } else { - $trail[] = $p->name; + $trail[] = l(strtolower($p->name), "forum/$p->tid"); } } } $output = "<div id=\"forum\">"; + $output .= "<div class=\"path\">". implode($trail, " » ") ."</div>"; + $output .= "<div class=\"title\">$title</div>"; $output .= theme("forum_theme_list", $forums, $parents, $tid); if ($tid) { @@ -489,7 +486,8 @@ function forum_theme_display($forums, $topics, $parents, $tid, $sortby, $forum_p $output .= "</div>"; - theme("box", implode($trail, " » "), $output); + theme("header"); + theme("box", NULL, $output); theme("footer"); } diff --git a/modules/node.module b/modules/node.module index f2f53a69b..79ca87943 100644 --- a/modules/node.module +++ b/modules/node.module @@ -1553,7 +1553,7 @@ function node_page() { switch ($op) { case "add": - theme("box", t("Create new $name"), node_add(arg(2))); + theme("box", t("Submit $name"), node_add(arg(2))); break; case "edit": theme("box", t("Edit $name"), node_edit(arg(2))); diff --git a/modules/node/node.module b/modules/node/node.module index f2f53a69b..79ca87943 100644 --- a/modules/node/node.module +++ b/modules/node/node.module @@ -1553,7 +1553,7 @@ function node_page() { switch ($op) { case "add": - theme("box", t("Create new $name"), node_add(arg(2))); + theme("box", t("Submit $name"), node_add(arg(2))); break; case "edit": theme("box", t("Edit $name"), node_edit(arg(2))); diff --git a/modules/story.module b/modules/story.module index 5ff152742..1b6a4b1ea 100644 --- a/modules/story.module +++ b/modules/story.module @@ -9,12 +9,12 @@ function story_help($section = "admin/story/help") { case "admin/system/modules/story": $output = "Stories are like newspaper articles. They tend to follow a publishing flow of <b>submit -> moderate -> post to the main page -> comments</b>. Below you may fix a minimum word count for stories and also write some submission or content guidelines for users wanting to post a story."; break; - case "admin/story/help": + case "admin/story/help": $output = "<p>The story module lets your users submit articles for consideration by the rest of the community, who can vote on them if moderation is enabled. Stories usually follow a publishing flow of <b>submit -> moderate -> post to the main page -> comments</b>. Administrators are able to shortcut this flow as desired.</p>"; $output .= "In ". l("site configuration >> modules >> story", "admin/system/modules/story") ." you can set up an introductory text for story authors, and a floor on the number of words which may be included in a story. This is designed to help discourage the submission of trivially short stories."; break; } - + return t($output); } diff --git a/modules/story/story.module b/modules/story/story.module index 5ff152742..1b6a4b1ea 100644 --- a/modules/story/story.module +++ b/modules/story/story.module @@ -9,12 +9,12 @@ function story_help($section = "admin/story/help") { case "admin/system/modules/story": $output = "Stories are like newspaper articles. They tend to follow a publishing flow of <b>submit -> moderate -> post to the main page -> comments</b>. Below you may fix a minimum word count for stories and also write some submission or content guidelines for users wanting to post a story."; break; - case "admin/story/help": + case "admin/story/help": $output = "<p>The story module lets your users submit articles for consideration by the rest of the community, who can vote on them if moderation is enabled. Stories usually follow a publishing flow of <b>submit -> moderate -> post to the main page -> comments</b>. Administrators are able to shortcut this flow as desired.</p>"; $output .= "In ". l("site configuration >> modules >> story", "admin/system/modules/story") ." you can set up an introductory text for story authors, and a floor on the number of words which may be included in a story. This is designed to help discourage the submission of trivially short stories."; break; } - + return t($output); } diff --git a/modules/user.module b/modules/user.module index f8469639b..5b1069b60 100644 --- a/modules/user.module +++ b/modules/user.module @@ -334,7 +334,7 @@ function user_fields() { } // Make sure we return the default fields at least - return is_array($fields) ? $fields: array("uid", "name", "pass", "mail", "homepage", "mode", "sort", "threshold", "theme", "signature", "timestamp", "status", "timezone", "rating", "language", "init", "data", "rid"); + return is_array($fields) ? $fields: array("uid", "name", "pass", "mail", "homepage", "mode", "sort", "threshold", "theme", "signature", "timestamp", "status", "timezone", "language", "init", "data", "rid"); } /*** Module hooks **********************************************************/ @@ -886,7 +886,7 @@ function user_register($edit = array()) { user_role_init(); // TODO: is this necessary? Won't session_write replicate this? unset($edit["session"]); - $account = user_save("", array_merge(array("name" => $edit["name"], "pass" => $pass, "init" => $edit["mail"], "mail" => $edit["mail"], "rid" => _user_authenticated_id(), "rating" => 0, "status" => (variable_get("user_register", 1) == 1 ? 1 : 0)), $data)); + $account = user_save("", array_merge(array("name" => $edit["name"], "pass" => $pass, "init" => $edit["mail"], "mail" => $edit["mail"], "rid" => _user_authenticated_id(), "status" => (variable_get("user_register", 1) == 1 ? 1 : 0)), $data)); watchdog("user", "new user: '". $edit["name"] ."' <". $edit["mail"] .">", l(t("edit user"), "admin/user/edit/$account->uid")); $variables = array("%username" => $edit["name"], "%site" => variable_get("site_name", "drupal"), "%password" => $pass, "%uri" => $base_url, "%uri_brief" => substr($base_url, strlen("http://")), "%mailto" => $edit["mail"], "%date" => format_date(time())); @@ -1012,13 +1012,12 @@ function user_edit($edit = array()) { */ if (!user_access("administer users")) { - if (array_intersect(array_keys($edit), array("rid", "init", "rating", "session"))) { + if (array_intersect(array_keys($edit), array("rid", "init", "session"))) { watchdog("warning", "detected malicious attempt to alter a protected database field"); } $edit["rid"] = $user->rid; $edit["init"] = $user->init; - $edit["rating"] = $user->rating; $edit["session"] = $user->session; } diff --git a/modules/user/user.module b/modules/user/user.module index f8469639b..5b1069b60 100644 --- a/modules/user/user.module +++ b/modules/user/user.module @@ -334,7 +334,7 @@ function user_fields() { } // Make sure we return the default fields at least - return is_array($fields) ? $fields: array("uid", "name", "pass", "mail", "homepage", "mode", "sort", "threshold", "theme", "signature", "timestamp", "status", "timezone", "rating", "language", "init", "data", "rid"); + return is_array($fields) ? $fields: array("uid", "name", "pass", "mail", "homepage", "mode", "sort", "threshold", "theme", "signature", "timestamp", "status", "timezone", "language", "init", "data", "rid"); } /*** Module hooks **********************************************************/ @@ -886,7 +886,7 @@ function user_register($edit = array()) { user_role_init(); // TODO: is this necessary? Won't session_write replicate this? unset($edit["session"]); - $account = user_save("", array_merge(array("name" => $edit["name"], "pass" => $pass, "init" => $edit["mail"], "mail" => $edit["mail"], "rid" => _user_authenticated_id(), "rating" => 0, "status" => (variable_get("user_register", 1) == 1 ? 1 : 0)), $data)); + $account = user_save("", array_merge(array("name" => $edit["name"], "pass" => $pass, "init" => $edit["mail"], "mail" => $edit["mail"], "rid" => _user_authenticated_id(), "status" => (variable_get("user_register", 1) == 1 ? 1 : 0)), $data)); watchdog("user", "new user: '". $edit["name"] ."' <". $edit["mail"] .">", l(t("edit user"), "admin/user/edit/$account->uid")); $variables = array("%username" => $edit["name"], "%site" => variable_get("site_name", "drupal"), "%password" => $pass, "%uri" => $base_url, "%uri_brief" => substr($base_url, strlen("http://")), "%mailto" => $edit["mail"], "%date" => format_date(time())); @@ -1012,13 +1012,12 @@ function user_edit($edit = array()) { */ if (!user_access("administer users")) { - if (array_intersect(array_keys($edit), array("rid", "init", "rating", "session"))) { + if (array_intersect(array_keys($edit), array("rid", "init", "session"))) { watchdog("warning", "detected malicious attempt to alter a protected database field"); } $edit["rid"] = $user->rid; $edit["init"] = $user->init; - $edit["rating"] = $user->rating; $edit["session"] = $user->session; } |