diff options
52 files changed, 334 insertions, 356 deletions
diff --git a/modules/admin.module b/modules/admin.module index 32a4bd704..e72a30745 100644 --- a/modules/admin.module +++ b/modules/admin.module @@ -28,7 +28,7 @@ function admin_help($section) { function admin_link($type) { if ($type == "system" && user_access("access administration pages")) { - menu("admin", t("administer"), NULL, NULL, 9); + menu("admin", t("administer"), NULL, 9); } } diff --git a/modules/aggregator.module b/modules/aggregator.module index 956e266bf..c81248028 100644 --- a/modules/aggregator.module +++ b/modules/aggregator.module @@ -2,12 +2,11 @@ // $Id$ -function import_help($section = "admin/import/help") { +function import_help($section = "admin/help#import") { $output = ""; switch ($section) { - case 'admin/help': - case 'admin/import/help': + case 'admin/help#import': $output .= "<p>Thousands of web sites, especially news sites and weblogs, syndicate their most recent site content for others to display. The syndicated content always includes titles, also known as headlines, for the newest published stories. Each headline acts as a direct link to the stories on the remote site. Along with the headline, most sites typically provide either the first few paragraphs of the story or a short summary. Many individuals use client-based news aggregators on their personal computer to aggregate content, such as %amphetadesk</p>"; $output .= "<p>Drupal also has a news aggregator built in as a standard feature. With it, you can subscribe to feeds from other sites and display their content for your site users. Simply enable the import module in site administration and enter the feeds that you choose.</p>"; $output .= "<h3>What do I need to subscribe to a feed?</h3>"; @@ -99,12 +98,12 @@ function import_link($type) { if ($type == "system") { if (user_access("administer news feeds")) { - menu("admin/node/syndication", t("syndication"), NULL, NULL, 5); - menu("admin/node/syndication/news", t("RSS/RDF"), "import_admin", import_help("admin/node/syndication/news")); - menu("admin/node/syndication/news/add/feed", t("new feed"), "import_admin", import_help("admin/node/syndication/news/add/feed"), 2); - menu("admin/node/syndication/news/add/bundle", t("new bundle"), "import_admin", import_help("admin/node/syndication/news/add/bundle"), 3); - menu("admin/node/syndication/news/tag", t("tag items"), "import_admin", import_help("admin/node/syndication/news/tag"), 4); - menu("admin/node/syndication/news/help", t("help"), "import_help", NULL, 9); + menu("admin/node/syndication", t("syndication"), NULL, 5); + menu("admin/node/syndication/news", t("RSS/RDF"), "import_admin"); + menu("admin/node/syndication/news/add/feed", t("new feed"), "import_admin", 2); + menu("admin/node/syndication/news/add/bundle", t("new bundle"), "import_admin", 3); + menu("admin/node/syndication/news/tag", t("tag items"), "import_admin", 4); + menu("admin/node/syndication/news/help", t("help"), "import_help", 9); } } diff --git a/modules/aggregator/aggregator.module b/modules/aggregator/aggregator.module index 956e266bf..c81248028 100644 --- a/modules/aggregator/aggregator.module +++ b/modules/aggregator/aggregator.module @@ -2,12 +2,11 @@ // $Id$ -function import_help($section = "admin/import/help") { +function import_help($section = "admin/help#import") { $output = ""; switch ($section) { - case 'admin/help': - case 'admin/import/help': + case 'admin/help#import': $output .= "<p>Thousands of web sites, especially news sites and weblogs, syndicate their most recent site content for others to display. The syndicated content always includes titles, also known as headlines, for the newest published stories. Each headline acts as a direct link to the stories on the remote site. Along with the headline, most sites typically provide either the first few paragraphs of the story or a short summary. Many individuals use client-based news aggregators on their personal computer to aggregate content, such as %amphetadesk</p>"; $output .= "<p>Drupal also has a news aggregator built in as a standard feature. With it, you can subscribe to feeds from other sites and display their content for your site users. Simply enable the import module in site administration and enter the feeds that you choose.</p>"; $output .= "<h3>What do I need to subscribe to a feed?</h3>"; @@ -99,12 +98,12 @@ function import_link($type) { if ($type == "system") { if (user_access("administer news feeds")) { - menu("admin/node/syndication", t("syndication"), NULL, NULL, 5); - menu("admin/node/syndication/news", t("RSS/RDF"), "import_admin", import_help("admin/node/syndication/news")); - menu("admin/node/syndication/news/add/feed", t("new feed"), "import_admin", import_help("admin/node/syndication/news/add/feed"), 2); - menu("admin/node/syndication/news/add/bundle", t("new bundle"), "import_admin", import_help("admin/node/syndication/news/add/bundle"), 3); - menu("admin/node/syndication/news/tag", t("tag items"), "import_admin", import_help("admin/node/syndication/news/tag"), 4); - menu("admin/node/syndication/news/help", t("help"), "import_help", NULL, 9); + menu("admin/node/syndication", t("syndication"), NULL, 5); + menu("admin/node/syndication/news", t("RSS/RDF"), "import_admin"); + menu("admin/node/syndication/news/add/feed", t("new feed"), "import_admin", 2); + menu("admin/node/syndication/news/add/bundle", t("new bundle"), "import_admin", 3); + menu("admin/node/syndication/news/tag", t("tag items"), "import_admin", 4); + menu("admin/node/syndication/news/help", t("help"), "import_help", 9); } } diff --git a/modules/block.module b/modules/block.module index 40c26c036..64f2d1b8b 100644 --- a/modules/block.module +++ b/modules/block.module @@ -1,11 +1,11 @@ <?php // $Id$ -function block_help($section = "admin/block/help") { +function block_help($section = "admin/help#block") { $output = ""; switch ($section) { - case 'admin/block/help': + case 'admin/help#block': $output .= "<p>Blocks are the boxes visible in the sidebar(s) of your web site. These are usually generated automatically by modules (e.g. recent forum topics), but you can also create your own blocks using either static HTML or dynamic PHP content.</p>"; $output .= "<p>The sidebar each block appears in depends on both which theme you're using (some are left-only, some right, some both), and on the settings in block management.</p><p>Whether a block is visible in the first place depends on three things:</p><ul><li>It must have its \"enabled\" box checked in block management.</li><li>If it has its \"custom\" box checked in block management, the user must have chosen to display it in their user preferences.</li><li>If the \"path\" field in block management is set, the visitor must be on a page that matches the path specification (more on this later).</li></ul>"; $output .= "<p>The block management screen also lets you specify the vertical sort-order of the blocks within a sidebar. You do this by assigning a <b>weight</b> to each block. Lighter blocks (smaller weight) \"float up\" towards the top of the sidebar. Heavier ones \"sink down\" towards the bottom of it. Once you've positioned things just so, you can preview what the layout will look like in different types of themes by clicking the preview placement link in the menu to the left.</p>"; @@ -60,10 +60,10 @@ function block_perm() { function block_link($type) { if ($type == "system" && user_access("administer blocks")) { - menu("admin/system/block", t("blocks"), "block_admin", block_help("admin/system/block"), 3); - menu("admin/system/block/add", t("new block"), "block_admin", block_help("admin/system/block/add"), 2); - menu("admin/system/block/preview", t("preview placement"), "block_admin", block_help("admin/system/block/preview"), 3); - menu("admin/system/block/help", t("help"), "block_help", NULL, 9); + menu("admin/system/block", t("blocks"), "block_admin", 3); + menu("admin/system/block/add", t("new block"), "block_admin", 2); + menu("admin/system/block/preview", t("preview placement"), "block_admin", 3); + menu("admin/system/block/help", t("help"), "block_help", 9); } } diff --git a/modules/block/block.module b/modules/block/block.module index 40c26c036..64f2d1b8b 100644 --- a/modules/block/block.module +++ b/modules/block/block.module @@ -1,11 +1,11 @@ <?php // $Id$ -function block_help($section = "admin/block/help") { +function block_help($section = "admin/help#block") { $output = ""; switch ($section) { - case 'admin/block/help': + case 'admin/help#block': $output .= "<p>Blocks are the boxes visible in the sidebar(s) of your web site. These are usually generated automatically by modules (e.g. recent forum topics), but you can also create your own blocks using either static HTML or dynamic PHP content.</p>"; $output .= "<p>The sidebar each block appears in depends on both which theme you're using (some are left-only, some right, some both), and on the settings in block management.</p><p>Whether a block is visible in the first place depends on three things:</p><ul><li>It must have its \"enabled\" box checked in block management.</li><li>If it has its \"custom\" box checked in block management, the user must have chosen to display it in their user preferences.</li><li>If the \"path\" field in block management is set, the visitor must be on a page that matches the path specification (more on this later).</li></ul>"; $output .= "<p>The block management screen also lets you specify the vertical sort-order of the blocks within a sidebar. You do this by assigning a <b>weight</b> to each block. Lighter blocks (smaller weight) \"float up\" towards the top of the sidebar. Heavier ones \"sink down\" towards the bottom of it. Once you've positioned things just so, you can preview what the layout will look like in different types of themes by clicking the preview placement link in the menu to the left.</p>"; @@ -60,10 +60,10 @@ function block_perm() { function block_link($type) { if ($type == "system" && user_access("administer blocks")) { - menu("admin/system/block", t("blocks"), "block_admin", block_help("admin/system/block"), 3); - menu("admin/system/block/add", t("new block"), "block_admin", block_help("admin/system/block/add"), 2); - menu("admin/system/block/preview", t("preview placement"), "block_admin", block_help("admin/system/block/preview"), 3); - menu("admin/system/block/help", t("help"), "block_help", NULL, 9); + menu("admin/system/block", t("blocks"), "block_admin", 3); + menu("admin/system/block/add", t("new block"), "block_admin", 2); + menu("admin/system/block/preview", t("preview placement"), "block_admin", 3); + menu("admin/system/block/help", t("help"), "block_help", 9); } } diff --git a/modules/blog.module b/modules/blog.module index ba27e1f41..b72bb7719 100644 --- a/modules/blog.module +++ b/modules/blog.module @@ -69,8 +69,7 @@ function blog_help($section) { $output =""; switch ($section) { - case 'admin/blog/help': - case 'admin/help': + case 'admin/help#blog': $output .= "<p>Drupal's blog module allows registered users to maintain an online weblog (commonly known as a blog), often referred to as an online journal or diary. These can be filled with daily thoughts, poetry, boneless blabber, spiritual theories, intimate details, valuable experiences, cynical rants, semi-coherent comments, writing experiments, artistic babblings, critics on current facts, fresh insights, diverse dreams, chronicles and mumbling madness available for public consumption.</p>"; $output .= "<p>Blogs are made up of individual entries (nodes) that are timestamped and are typically viewed by day as you would a diary. Blogs often contain links to things you've seen and/or agree/disagree with. A typical example of a long term blog can be seen at %scripting-com.</p>"; $output .= "<p>The blog module adds a \"user blogs\" navigation link to the site, which takes any visitor to a page that displays the most recent blog entries from all the users on the site. Personal user menus gain a \"create a blog entry\" link (which takes you to a submission form) and a \"view personal blog\" link (which displays your blog entries as other people will see them). On the bottom of each of your own blog entries, there is an \"edit this blog entry\" link that lets you edit or delete that entry.</p>"; @@ -253,10 +252,10 @@ function blog_link($type, $node = 0, $main) { if ($type == "system") { if (user_access("maintain personal blog")) { - menu("node/add/blog", t("blog entry"), "blog_page", NULL, 0); + menu("node/add/blog", t("blog entry"), "blog_page", 0); } if (user_access("maintain personal blog")) { - menu("blog/" . $user->uid, t("my blog"), "user_page", NULL, 1); + menu("blog/" . $user->uid, t("my blog"), "user_page", 1); } } diff --git a/modules/blog/blog.module b/modules/blog/blog.module index ba27e1f41..b72bb7719 100644 --- a/modules/blog/blog.module +++ b/modules/blog/blog.module @@ -69,8 +69,7 @@ function blog_help($section) { $output =""; switch ($section) { - case 'admin/blog/help': - case 'admin/help': + case 'admin/help#blog': $output .= "<p>Drupal's blog module allows registered users to maintain an online weblog (commonly known as a blog), often referred to as an online journal or diary. These can be filled with daily thoughts, poetry, boneless blabber, spiritual theories, intimate details, valuable experiences, cynical rants, semi-coherent comments, writing experiments, artistic babblings, critics on current facts, fresh insights, diverse dreams, chronicles and mumbling madness available for public consumption.</p>"; $output .= "<p>Blogs are made up of individual entries (nodes) that are timestamped and are typically viewed by day as you would a diary. Blogs often contain links to things you've seen and/or agree/disagree with. A typical example of a long term blog can be seen at %scripting-com.</p>"; $output .= "<p>The blog module adds a \"user blogs\" navigation link to the site, which takes any visitor to a page that displays the most recent blog entries from all the users on the site. Personal user menus gain a \"create a blog entry\" link (which takes you to a submission form) and a \"view personal blog\" link (which displays your blog entries as other people will see them). On the bottom of each of your own blog entries, there is an \"edit this blog entry\" link that lets you edit or delete that entry.</p>"; @@ -253,10 +252,10 @@ function blog_link($type, $node = 0, $main) { if ($type == "system") { if (user_access("maintain personal blog")) { - menu("node/add/blog", t("blog entry"), "blog_page", NULL, 0); + menu("node/add/blog", t("blog entry"), "blog_page", 0); } if (user_access("maintain personal blog")) { - menu("blog/" . $user->uid, t("my blog"), "user_page", NULL, 1); + menu("blog/" . $user->uid, t("my blog"), "user_page", 1); } } diff --git a/modules/bloggerapi.module b/modules/bloggerapi.module index acd080677..02244f3ff 100644 --- a/modules/bloggerapi.module +++ b/modules/bloggerapi.module @@ -337,8 +337,7 @@ function bloggerapi_help($section) { $output = ""; switch ($section) { - case 'admin/bloggerapi/help': - case 'admin/help': + case 'admin/help#bloggerapi': $output = "<h3>Introduction</h3>"; $output .= "<p>%blogger-com, the well-known public weblog service, provides an application programing interface (API) to allow remote procedure calls (RPC) to the Blogger service. Drupal supports this %blogger-api, which means that many remote clients (e.g. %client-radio, %client-blogbuddy, %client-w_bloggar, and %client-textrouter) may post to Drupal. These clients provide a bevy of interesting capabilities like offline composing, spellcheck, and WYSIWYG editing; many folks prefer to blog with a client application over typical web forms. By supporting the Blogger API, Drupal grows grander than a web site engine, it's a <i>content accepting machine</i>™.</p>"; $output .= "<p>The %blogger_api uses the %xml-rpc protocol for communicating with the outside world. %xml-rpc, originally developed by Dave Winer of %userland-software, is a simple XML-based RPC specification ideally suited to the web. Drupal also uses %xml-rpc for several other tasks (e.g. notifiying %weblogs-com of blog updates and making/accepting %dist-auth requests)</p>"; diff --git a/modules/book.module b/modules/book.module index d27591c80..60ae902ed 100644 --- a/modules/book.module +++ b/modules/book.module @@ -71,10 +71,10 @@ function book_link($type, $node = 0, $main = 0) { if ($type == "system") { if (user_access("maintain books")) { - menu("node/add/book", t("book page"), "book_page", NULL, 0); - menu("admin/node/book", t("books"), NULL, NULL, 4); - menu("admin/node/book/orphan", t("orphan pages"), NULL, NULL, 8); - menu("admin/node/book/help", t("help"), NULL, NULL, 9); + menu("node/add/book", t("book page"), "book_page", 0); + menu("admin/node/book", t("books"), NULL, 4); + menu("admin/node/book/orphan", t("orphan pages"), NULL, 8); + menu("admin/node/book/help", t("help"), NULL, 9); $result = db_query("SELECT n.nid, n.title FROM {node} n INNER JOIN {book} b ON n.nid = b.nid WHERE b.parent = 0 ORDER BY b.weight, n.title"); while ($book = db_fetch_object($result)) { @@ -834,13 +834,11 @@ function book_admin() { } } -function book_help($section = "admin/node/book/help") { +function book_help($section = "admin/help#book") { $output = ""; switch ($section) { - case 'admin/node/book/help': - case 'admin/book/help': - case 'admin/help': + case 'admin/help#book': $output .= "<p>The book organises content into a nested hierarchical structure. It is particularly good for manuals, Frequently Asked Questions (FAQs) and the like, allowing you to have chapters, sections, etc.</p>"; $output .= "<p>A book is simply a collection of nodes that have been linked together. These nodes are usually of type <i>book page</i>, but you can insert nodes of any type into a book outline. Every node in the book has a <i>parent</i> node which \"contains\" it. This is how book.module establishes its hierarchy. At any given level in the hierarchy, a book can contain many nodes. All these sibling nodes are sorted according to the <i>weight</i> that you give them.</p>"; $output .= "<p>A book page is a special node type that allows you to embed PHP within the body of the page. This capability is only offerred to administrators, since malicious users could abuse this power. In addiiton, book pages contain a <i>log message</i> field which helps your users understand the motivation behind an edit of a book page. Each edited version of a book page is stored as a new revision of a node. This capability makes it easy to revert to an old version of a page, should that be desirable.</p>"; diff --git a/modules/book/book.module b/modules/book/book.module index d27591c80..60ae902ed 100644 --- a/modules/book/book.module +++ b/modules/book/book.module @@ -71,10 +71,10 @@ function book_link($type, $node = 0, $main = 0) { if ($type == "system") { if (user_access("maintain books")) { - menu("node/add/book", t("book page"), "book_page", NULL, 0); - menu("admin/node/book", t("books"), NULL, NULL, 4); - menu("admin/node/book/orphan", t("orphan pages"), NULL, NULL, 8); - menu("admin/node/book/help", t("help"), NULL, NULL, 9); + menu("node/add/book", t("book page"), "book_page", 0); + menu("admin/node/book", t("books"), NULL, 4); + menu("admin/node/book/orphan", t("orphan pages"), NULL, 8); + menu("admin/node/book/help", t("help"), NULL, 9); $result = db_query("SELECT n.nid, n.title FROM {node} n INNER JOIN {book} b ON n.nid = b.nid WHERE b.parent = 0 ORDER BY b.weight, n.title"); while ($book = db_fetch_object($result)) { @@ -834,13 +834,11 @@ function book_admin() { } } -function book_help($section = "admin/node/book/help") { +function book_help($section = "admin/help#book") { $output = ""; switch ($section) { - case 'admin/node/book/help': - case 'admin/book/help': - case 'admin/help': + case 'admin/help#book': $output .= "<p>The book organises content into a nested hierarchical structure. It is particularly good for manuals, Frequently Asked Questions (FAQs) and the like, allowing you to have chapters, sections, etc.</p>"; $output .= "<p>A book is simply a collection of nodes that have been linked together. These nodes are usually of type <i>book page</i>, but you can insert nodes of any type into a book outline. Every node in the book has a <i>parent</i> node which \"contains\" it. This is how book.module establishes its hierarchy. At any given level in the hierarchy, a book can contain many nodes. All these sibling nodes are sorted according to the <i>weight</i> that you give them.</p>"; $output .= "<p>A book page is a special node type that allows you to embed PHP within the body of the page. This capability is only offerred to administrators, since malicious users could abuse this power. In addiiton, book pages contain a <i>log message</i> field which helps your users understand the motivation behind an edit of a book page. Each edited version of a book page is stored as a new revision of a node. This capability makes it easy to revert to an old version of a page, should that be desirable.</p>"; diff --git a/modules/cloud.module b/modules/cloud.module index 17f8fa8c3..fe293237b 100644 --- a/modules/cloud.module +++ b/modules/cloud.module @@ -1,13 +1,11 @@ <?php // $Id$ -function cloud_help($section = "admin/node/syndication/cloud/help") { +function cloud_help($section = "admin/help#cloud") { $output = ""; switch ($section) { - case 'admin/help': - case 'admin/cloud/help': - case 'admin/node/syndication/cloud/help': + case 'admin/help#cloud': $output .= "The cloud monitor tracks or crawls other interesting web sites and displays their last modification dates. Visitors to the host site learn about relevant sites and can easily see if there is new content. Here is how it works:"; $output .= "<ul>"; $output .= "<li>The site administrator enters names and URLs of the relevant pages on the %cloud-add page.</li>"; @@ -54,9 +52,9 @@ function cloud_link($type) { if ($type == "system") { if (user_access("administer site cloud")) { - menu("admin/node/syndication/cloud", t("site cloud"), "cloud_admin", cloud_help("admin/node/syndication/cloud")); - menu("admin/node/syndication/cloud/add", t("add new site"), "cloud_admin", cloud_help("admin/node/syndication/cloud/add")); - menu("admin/node/syndication/cloud/help", t("help"), "cloud_help", NULL, 9); + menu("admin/node/syndication/cloud", t("site cloud"), "cloud_admin"); + menu("admin/node/syndication/cloud/add", t("add new site"), "cloud_admin"); + menu("admin/node/syndication/cloud/help", t("help"), "cloud_help", 9); } } diff --git a/modules/comment.module b/modules/comment.module index a03f236d9..9a590471d 100644 --- a/modules/comment.module +++ b/modules/comment.module @@ -1,12 +1,11 @@ <?php // $Id$ -function comment_help($section = "admin/comment/help") { +function comment_help($section = "admin/help#comment") { $output = ""; switch ($section) { - case 'admin/help': - case 'admin/comment/help': + case 'admin/help#comment': $output .= "<p>When enabled, the Drupal comment module creates a discussion board for each Drupal node. Users can post comments to discuss a forum topic, weblog post, collaborative book page, etc.</p>"; $output .= "<h3>User control of comment display</h3>"; $output .= "<p>Attached to each comment board is a control panel for customizing the way that comments are displayed. Users can control the chronological ordering of posts (newest or oldest first) and the number of posts to display on each page. Additional settings include:</p>"; @@ -843,21 +842,21 @@ function comment_link($type, $node = 0, $main = 0) { if ($type == "system") { if (user_access("administer comments")) { - menu("admin/comment", t("comments"), "comment_admin", comment_help("admin/comment"), 1); - menu("admin/comment/comments", t("overview"), NULL, comment_help("admin/comment/comments"), 2); - menu("admin/comment/comments/0", t("new/updated"), "comment_admin", comment_help("admin/comment/comments/0"), 1); - menu("admin/comment/comments/1", t("approval queue"), "comment_admin", comment_help("admin/comment/comments/1"), 2); - menu("admin/comment/search", t("search"), "comment_admin", comment_help("admin/comment/search"), 8); - menu("admin/comment/help", t("help"), "comment_help", NULL, 9); - menu("admin/comment/edit", t("edit comment"), "comment_admin", NULL, 0, 1); + menu("admin/comment", t("comments"), "comment_admin", 1); + menu("admin/comment/comments", t("overview"), NULL, 2); + menu("admin/comment/comments/0", t("new/updated"), "comment_admin", 1); + menu("admin/comment/comments/1", t("approval queue"), "comment_admin", 2); + menu("admin/comment/search", t("search"), "comment_admin", 8); + menu("admin/comment/help", t("help"), "comment_help", 9); + menu("admin/comment/edit", t("edit comment"), "comment_admin", 0, 1); // comment settings: if (user_access("administer moderation")) { - menu("admin/comment/moderation", t("moderation"), NULL, comment_help("admin/comment/moderation"), 3); - menu("admin/comment/moderation/votes", t("votes"), "comment_admin", comment_help("admin/comment/moderation/votes")); - menu("admin/comment/moderation/matrix", t("matrix"), "comment_admin", comment_help("admin/comment/moderation/matrix")); - menu("admin/comment/moderation/filters", t("thresholds"), "comment_admin", comment_help("admin/comment/moderation/filters")); - menu("admin/comment/moderation/roles", t("initial scores"), "comment_admin", comment_help("admin/comment/roles"), 6); + menu("admin/comment/moderation", t("moderation"), NULL, 3); + menu("admin/comment/moderation/votes", t("votes"), "comment_admin"); + menu("admin/comment/moderation/matrix", t("matrix"), "comment_admin"); + menu("admin/comment/moderation/filters", t("thresholds"), "comment_admin"); + menu("admin/comment/moderation/roles", t("initial scores"), "comment_admin", 6); } } } diff --git a/modules/comment/comment.module b/modules/comment/comment.module index a03f236d9..9a590471d 100644 --- a/modules/comment/comment.module +++ b/modules/comment/comment.module @@ -1,12 +1,11 @@ <?php // $Id$ -function comment_help($section = "admin/comment/help") { +function comment_help($section = "admin/help#comment") { $output = ""; switch ($section) { - case 'admin/help': - case 'admin/comment/help': + case 'admin/help#comment': $output .= "<p>When enabled, the Drupal comment module creates a discussion board for each Drupal node. Users can post comments to discuss a forum topic, weblog post, collaborative book page, etc.</p>"; $output .= "<h3>User control of comment display</h3>"; $output .= "<p>Attached to each comment board is a control panel for customizing the way that comments are displayed. Users can control the chronological ordering of posts (newest or oldest first) and the number of posts to display on each page. Additional settings include:</p>"; @@ -843,21 +842,21 @@ function comment_link($type, $node = 0, $main = 0) { if ($type == "system") { if (user_access("administer comments")) { - menu("admin/comment", t("comments"), "comment_admin", comment_help("admin/comment"), 1); - menu("admin/comment/comments", t("overview"), NULL, comment_help("admin/comment/comments"), 2); - menu("admin/comment/comments/0", t("new/updated"), "comment_admin", comment_help("admin/comment/comments/0"), 1); - menu("admin/comment/comments/1", t("approval queue"), "comment_admin", comment_help("admin/comment/comments/1"), 2); - menu("admin/comment/search", t("search"), "comment_admin", comment_help("admin/comment/search"), 8); - menu("admin/comment/help", t("help"), "comment_help", NULL, 9); - menu("admin/comment/edit", t("edit comment"), "comment_admin", NULL, 0, 1); + menu("admin/comment", t("comments"), "comment_admin", 1); + menu("admin/comment/comments", t("overview"), NULL, 2); + menu("admin/comment/comments/0", t("new/updated"), "comment_admin", 1); + menu("admin/comment/comments/1", t("approval queue"), "comment_admin", 2); + menu("admin/comment/search", t("search"), "comment_admin", 8); + menu("admin/comment/help", t("help"), "comment_help", 9); + menu("admin/comment/edit", t("edit comment"), "comment_admin", 0, 1); // comment settings: if (user_access("administer moderation")) { - menu("admin/comment/moderation", t("moderation"), NULL, comment_help("admin/comment/moderation"), 3); - menu("admin/comment/moderation/votes", t("votes"), "comment_admin", comment_help("admin/comment/moderation/votes")); - menu("admin/comment/moderation/matrix", t("matrix"), "comment_admin", comment_help("admin/comment/moderation/matrix")); - menu("admin/comment/moderation/filters", t("thresholds"), "comment_admin", comment_help("admin/comment/moderation/filters")); - menu("admin/comment/moderation/roles", t("initial scores"), "comment_admin", comment_help("admin/comment/roles"), 6); + menu("admin/comment/moderation", t("moderation"), NULL, 3); + menu("admin/comment/moderation/votes", t("votes"), "comment_admin"); + menu("admin/comment/moderation/matrix", t("matrix"), "comment_admin"); + menu("admin/comment/moderation/filters", t("thresholds"), "comment_admin"); + menu("admin/comment/moderation/roles", t("initial scores"), "comment_admin", 6); } } } diff --git a/modules/drupal.module b/modules/drupal.module index 93ebc1205..85b9573f3 100644 --- a/modules/drupal.module +++ b/modules/drupal.module @@ -1,12 +1,11 @@ <?php // $Id$ -function drupal_help($section = "admin/drupal/help") { +function drupal_help($section = "admin/help#drupal") { $output = ""; switch ($section) { - case 'admin/help': - case 'admin/drupal/help': + case 'admin/help#drupal': $output .= "<p>The \"Drupal\" module features a capability whereby other drupal sites may <i>call home</i> to report their existence. In turn, this enables a pod of Drupal sites to find, cooperate and advertise each other.</p>"; $output .= "<p>Currently, the main application of this feature is the %drupal-sites. By default, fresh Drupal installations can use %Drupal as their <i>directory server</i> and report their existence. This reporting occurs via scheduled %xml-rpc pings.</p>"; $output .= "<p>Drupal administrators should simply enable this feature to get listed on the %drupal-sites; just set your site's name, e-mail address, slogan and mission statement. Then make sure that the field called <i>Drupal XML-RPC server</i> on the %drupal-settings page is set to http://www.drupal.org/xmlrpc.php, and enable this feature using the dropdown directly below.</p>"; @@ -20,7 +19,7 @@ function drupal_help($section = "admin/drupal/help") { case 'admin/system/modules/drupal': $output = t("Using this your Drupal site can \"call home\" and add itself to the Drupal directory. If you want it to add itself to a different directory server you can change the %Drupal-setting setting -- but the directory server has to be able to handle Drupal XML. To get a full site listing go to the %general and set:<ul><li>The site name,</li><li>The site E-Mail address,</li><li>The site slogan, and</li><li>The site mission statement.</li></ul>", array("%Drupal-setting" => l(t("Drupal XML-RPC server"), "admin/system/modules/drupal"), "%general" => l(t("site configuration"), "admin/system"))); break; - case 'user/help': + case 'user/help#drupal': $site = variable_get("site_name", "this web site"); $output = "<p>%drupal is the name of the software which powers %site. There are Drupal web sites all over the world, and many of them share their registration databases so that users may freely login to any Drupal site using a single <b>Drupal ID</b>.</p>\n"; @@ -159,7 +158,7 @@ function drupal_auth($username, $password, $server) { function drupal_page() { theme("header"); - theme("box", "Drupal", drupal_help("user/help")); + theme("box", "Drupal", drupal_help("user/help#drupal")); theme("footer"); } diff --git a/modules/drupal/drupal.module b/modules/drupal/drupal.module index 93ebc1205..85b9573f3 100644 --- a/modules/drupal/drupal.module +++ b/modules/drupal/drupal.module @@ -1,12 +1,11 @@ <?php // $Id$ -function drupal_help($section = "admin/drupal/help") { +function drupal_help($section = "admin/help#drupal") { $output = ""; switch ($section) { - case 'admin/help': - case 'admin/drupal/help': + case 'admin/help#drupal': $output .= "<p>The \"Drupal\" module features a capability whereby other drupal sites may <i>call home</i> to report their existence. In turn, this enables a pod of Drupal sites to find, cooperate and advertise each other.</p>"; $output .= "<p>Currently, the main application of this feature is the %drupal-sites. By default, fresh Drupal installations can use %Drupal as their <i>directory server</i> and report their existence. This reporting occurs via scheduled %xml-rpc pings.</p>"; $output .= "<p>Drupal administrators should simply enable this feature to get listed on the %drupal-sites; just set your site's name, e-mail address, slogan and mission statement. Then make sure that the field called <i>Drupal XML-RPC server</i> on the %drupal-settings page is set to http://www.drupal.org/xmlrpc.php, and enable this feature using the dropdown directly below.</p>"; @@ -20,7 +19,7 @@ function drupal_help($section = "admin/drupal/help") { case 'admin/system/modules/drupal': $output = t("Using this your Drupal site can \"call home\" and add itself to the Drupal directory. If you want it to add itself to a different directory server you can change the %Drupal-setting setting -- but the directory server has to be able to handle Drupal XML. To get a full site listing go to the %general and set:<ul><li>The site name,</li><li>The site E-Mail address,</li><li>The site slogan, and</li><li>The site mission statement.</li></ul>", array("%Drupal-setting" => l(t("Drupal XML-RPC server"), "admin/system/modules/drupal"), "%general" => l(t("site configuration"), "admin/system"))); break; - case 'user/help': + case 'user/help#drupal': $site = variable_get("site_name", "this web site"); $output = "<p>%drupal is the name of the software which powers %site. There are Drupal web sites all over the world, and many of them share their registration databases so that users may freely login to any Drupal site using a single <b>Drupal ID</b>.</p>\n"; @@ -159,7 +158,7 @@ function drupal_auth($username, $password, $server) { function drupal_page() { theme("header"); - theme("box", "Drupal", drupal_help("user/help")); + theme("box", "Drupal", drupal_help("user/help#drupal")); theme("footer"); } diff --git a/modules/forum.module b/modules/forum.module index 0edd25244..15a12bd59 100644 --- a/modules/forum.module +++ b/modules/forum.module @@ -630,12 +630,11 @@ function _forum_get_topic_order($sortby) { } } -function forum_help($section = "admin/forum/help") { +function forum_help($section = "admin/help#forum") { $output = ""; switch ($section) { - case 'admin/help': - case 'admin/forum/help': + case 'admin/help#forum': $output .= "<h3>Creating a forum</h3>"; $output .= "<p>The forum module uses taxonomy to organize itself. To create a forum you first have to create a %taxonomy. When doing this, choose a sensible name for it (such as \"fora\") and make sure under \"Types\" that \"forum\" is selected. Once you have done this, %taxo-terms to it. Each term will become a forum. If you fill in the description field, users will be given additonal information about the forum on the main forum page. For example: \"troubleshooting\" - \"Please ask your questions here.\"</p>"; $output .= "<p>When you are happy with your vocabulary, go to %forums and set <b>Forum vocabulary</b> to the one you have just created. There will now be fora active on the site. For users to access them they must have the \"access content\" %permission and to create a topic they must have the \"create forum topics\" %permission. These permissions can be set in the %permission pages.</p>"; diff --git a/modules/forum/forum.module b/modules/forum/forum.module index 0edd25244..15a12bd59 100644 --- a/modules/forum/forum.module +++ b/modules/forum/forum.module @@ -630,12 +630,11 @@ function _forum_get_topic_order($sortby) { } } -function forum_help($section = "admin/forum/help") { +function forum_help($section = "admin/help#forum") { $output = ""; switch ($section) { - case 'admin/help': - case 'admin/forum/help': + case 'admin/help#forum': $output .= "<h3>Creating a forum</h3>"; $output .= "<p>The forum module uses taxonomy to organize itself. To create a forum you first have to create a %taxonomy. When doing this, choose a sensible name for it (such as \"fora\") and make sure under \"Types\" that \"forum\" is selected. Once you have done this, %taxo-terms to it. Each term will become a forum. If you fill in the description field, users will be given additonal information about the forum on the main forum page. For example: \"troubleshooting\" - \"Please ask your questions here.\"</p>"; $output .= "<p>When you are happy with your vocabulary, go to %forums and set <b>Forum vocabulary</b> to the one you have just created. There will now be fora active on the site. For users to access them they must have the \"access content\" %permission and to create a topic they must have the \"create forum topics\" %permission. These permissions can be set in the %permission pages.</p>"; diff --git a/modules/help.module b/modules/help.module index cfb5e846d..f7477a2ab 100644 --- a/modules/help.module +++ b/modules/help.module @@ -3,8 +3,8 @@ function help_link($type) { if ($type == "system" && user_access("access administration pages")) { - menu("admin/help/glossary", t("glossary"), "help_glossary", NULL, 8); - menu("admin/help", t("help"), "help_help", NULL, 9); + menu("admin/help/glossary", t("glossary"), "help_glossary", 8); + menu("admin/help", t("help"), "help_help", 9); } } @@ -31,15 +31,18 @@ function help_glossary() { return $output; } -function help_help($section = "admin/help") { +function help_help($section = "admin/help#help") { $output = ""; switch ($section) { - case 'admin/help': + case 'admin/help#help': foreach (module_list() as $name) { - if (module_hook($name, "help")) { - $temp = module_invoke($name, "help", "admin/$name/help"); + if ($name == 'help') { + continue; + } + else if (module_hook($name, "help")) { + $temp = module_invoke($name, "help", "admin/help#$name"); if (!empty($temp)) { $links[] = l($name, "admin/help#$name"); $output .= "<h2><a id=\"$name\">". ucfirst($name) ." module</a></h2>"; diff --git a/modules/help/help.module b/modules/help/help.module index cfb5e846d..f7477a2ab 100644 --- a/modules/help/help.module +++ b/modules/help/help.module @@ -3,8 +3,8 @@ function help_link($type) { if ($type == "system" && user_access("access administration pages")) { - menu("admin/help/glossary", t("glossary"), "help_glossary", NULL, 8); - menu("admin/help", t("help"), "help_help", NULL, 9); + menu("admin/help/glossary", t("glossary"), "help_glossary", 8); + menu("admin/help", t("help"), "help_help", 9); } } @@ -31,15 +31,18 @@ function help_glossary() { return $output; } -function help_help($section = "admin/help") { +function help_help($section = "admin/help#help") { $output = ""; switch ($section) { - case 'admin/help': + case 'admin/help#help': foreach (module_list() as $name) { - if (module_hook($name, "help")) { - $temp = module_invoke($name, "help", "admin/$name/help"); + if ($name == 'help') { + continue; + } + else if (module_hook($name, "help")) { + $temp = module_invoke($name, "help", "admin/help#$name"); if (!empty($temp)) { $links[] = l($name, "admin/help#$name"); $output .= "<h2><a id=\"$name\">". ucfirst($name) ." module</a></h2>"; diff --git a/modules/import.module b/modules/import.module index 956e266bf..c81248028 100644 --- a/modules/import.module +++ b/modules/import.module @@ -2,12 +2,11 @@ // $Id$ -function import_help($section = "admin/import/help") { +function import_help($section = "admin/help#import") { $output = ""; switch ($section) { - case 'admin/help': - case 'admin/import/help': + case 'admin/help#import': $output .= "<p>Thousands of web sites, especially news sites and weblogs, syndicate their most recent site content for others to display. The syndicated content always includes titles, also known as headlines, for the newest published stories. Each headline acts as a direct link to the stories on the remote site. Along with the headline, most sites typically provide either the first few paragraphs of the story or a short summary. Many individuals use client-based news aggregators on their personal computer to aggregate content, such as %amphetadesk</p>"; $output .= "<p>Drupal also has a news aggregator built in as a standard feature. With it, you can subscribe to feeds from other sites and display their content for your site users. Simply enable the import module in site administration and enter the feeds that you choose.</p>"; $output .= "<h3>What do I need to subscribe to a feed?</h3>"; @@ -99,12 +98,12 @@ function import_link($type) { if ($type == "system") { if (user_access("administer news feeds")) { - menu("admin/node/syndication", t("syndication"), NULL, NULL, 5); - menu("admin/node/syndication/news", t("RSS/RDF"), "import_admin", import_help("admin/node/syndication/news")); - menu("admin/node/syndication/news/add/feed", t("new feed"), "import_admin", import_help("admin/node/syndication/news/add/feed"), 2); - menu("admin/node/syndication/news/add/bundle", t("new bundle"), "import_admin", import_help("admin/node/syndication/news/add/bundle"), 3); - menu("admin/node/syndication/news/tag", t("tag items"), "import_admin", import_help("admin/node/syndication/news/tag"), 4); - menu("admin/node/syndication/news/help", t("help"), "import_help", NULL, 9); + menu("admin/node/syndication", t("syndication"), NULL, 5); + menu("admin/node/syndication/news", t("RSS/RDF"), "import_admin"); + menu("admin/node/syndication/news/add/feed", t("new feed"), "import_admin", 2); + menu("admin/node/syndication/news/add/bundle", t("new bundle"), "import_admin", 3); + menu("admin/node/syndication/news/tag", t("tag items"), "import_admin", 4); + menu("admin/node/syndication/news/help", t("help"), "import_help", 9); } } diff --git a/modules/jabber.module b/modules/jabber.module index 7d31bf17b..67b6d483a 100644 --- a/modules/jabber.module +++ b/modules/jabber.module @@ -9,7 +9,7 @@ function jabber_help($section) { $output = t("Enables login with Jabber ID and password."); break; - case 'user/help': + case 'user/help#jabber': $site = variable_get("site_name", "this web site"); $output = "<p>%jabber is an %opensource instant messaging system designed to give the power of choice and freedom back to the users of instant messaging. Not only does Jabber allow its users to use (and create) clients for numerous platforms, but it allows people to communicate to whomever they want in the way which is most convenient for them.</p>"; @@ -163,7 +163,7 @@ function jabber_auth($username, $password, $server) { function jabber_page() { theme("header"); - theme("box", "Jabber", jabber_help("user/help")); + theme("box", "Jabber", jabber_help("user/help#jabber")); theme("footer"); } diff --git a/modules/locale.module b/modules/locale.module index faecd98b5..738dcfc17 100644 --- a/modules/locale.module +++ b/modules/locale.module @@ -1,12 +1,11 @@ <?php // $Id$ -function locale_help($section = "admin/locale/help") { +function locale_help($section = "admin/help#locale") { $output = ""; switch ($section) { - case 'admin/help': - case 'admin/locale/help': + case 'admin/help#locale': $output .= "<p>Most programs are written and documented in English, and use English to interact with users. This is also true for a great deal of web sites. However, most people are less comfortable with English than with their native language, and would prefer to use their mother tongue as much as possible. Many people love see their web site showing a lot less English, and far more of their own language.</p>"; $output .= "<p>Therefore Drupal provides a framework to setup a multi-lingual web site, or to overwrite the default English texts. We explored the various alternatives to support internationalization (I18N) and decided to design the framework in such a way that the impact of internationalization on drupal's sources is minimized, modular and doesn't require a HTML or PHP wizard to maintain translations. Maintaining translations had to be simple so it became as easy as filling out forms on the administration page.</p>"; $output .= "<h3>How to translate texts</h3>"; @@ -65,16 +64,16 @@ function locale_link($type) { if ($type == "system") { if (user_access("administer locales")) { - menu("admin/locale", t("localization"), NULL, locale_help("admin/locale"), 5); - menu("admin/locale/search", t("search string"), "locale_admin", locale_help("admin/locale/search"), 8); - menu("admin/locale/help", t("help"), "locale_help", NULL, 9); - menu("admin/locale/edit", t("edit string"), "locale_admin", NULL, 0, 1); // hidden menu - menu("admin/locale/delete", t("delete string"), "locale_admin", NULL, 0, 1); // hidden menu + menu("admin/locale", t("localization"), NULL, 5); + menu("admin/locale/search", t("search string"), "locale_admin", 8); + menu("admin/locale/help", t("help"), "locale_help", 9); + menu("admin/locale/edit", t("edit string"), "locale_admin", 0, 1); // hidden menu + menu("admin/locale/delete", t("delete string"), "locale_admin", 0, 1); // hidden menu foreach ($languages as $key => $value) { - menu("admin/locale/$key", "$value", NULL, locale_help("admin/locale")); - menu("admin/locale/$key/translated", t("translated strings"), "locale_admin", locale_help("admin/locale/translated")); - menu("admin/locale/$key/untranslated", t("untranslated strings"), "locale_admin", locale_help("admin/locale/untranslated")); + menu("admin/locale/$key", "$value", NULL); + menu("admin/locale/$key/translated", t("translated strings"), "locale_admin"); + menu("admin/locale/$key/untranslated", t("untranslated strings"), "locale_admin"); } } } diff --git a/modules/locale/locale.module b/modules/locale/locale.module index faecd98b5..738dcfc17 100644 --- a/modules/locale/locale.module +++ b/modules/locale/locale.module @@ -1,12 +1,11 @@ <?php // $Id$ -function locale_help($section = "admin/locale/help") { +function locale_help($section = "admin/help#locale") { $output = ""; switch ($section) { - case 'admin/help': - case 'admin/locale/help': + case 'admin/help#locale': $output .= "<p>Most programs are written and documented in English, and use English to interact with users. This is also true for a great deal of web sites. However, most people are less comfortable with English than with their native language, and would prefer to use their mother tongue as much as possible. Many people love see their web site showing a lot less English, and far more of their own language.</p>"; $output .= "<p>Therefore Drupal provides a framework to setup a multi-lingual web site, or to overwrite the default English texts. We explored the various alternatives to support internationalization (I18N) and decided to design the framework in such a way that the impact of internationalization on drupal's sources is minimized, modular and doesn't require a HTML or PHP wizard to maintain translations. Maintaining translations had to be simple so it became as easy as filling out forms on the administration page.</p>"; $output .= "<h3>How to translate texts</h3>"; @@ -65,16 +64,16 @@ function locale_link($type) { if ($type == "system") { if (user_access("administer locales")) { - menu("admin/locale", t("localization"), NULL, locale_help("admin/locale"), 5); - menu("admin/locale/search", t("search string"), "locale_admin", locale_help("admin/locale/search"), 8); - menu("admin/locale/help", t("help"), "locale_help", NULL, 9); - menu("admin/locale/edit", t("edit string"), "locale_admin", NULL, 0, 1); // hidden menu - menu("admin/locale/delete", t("delete string"), "locale_admin", NULL, 0, 1); // hidden menu + menu("admin/locale", t("localization"), NULL, 5); + menu("admin/locale/search", t("search string"), "locale_admin", 8); + menu("admin/locale/help", t("help"), "locale_help", 9); + menu("admin/locale/edit", t("edit string"), "locale_admin", 0, 1); // hidden menu + menu("admin/locale/delete", t("delete string"), "locale_admin", 0, 1); // hidden menu foreach ($languages as $key => $value) { - menu("admin/locale/$key", "$value", NULL, locale_help("admin/locale")); - menu("admin/locale/$key/translated", t("translated strings"), "locale_admin", locale_help("admin/locale/translated")); - menu("admin/locale/$key/untranslated", t("untranslated strings"), "locale_admin", locale_help("admin/locale/untranslated")); + menu("admin/locale/$key", "$value", NULL); + menu("admin/locale/$key/translated", t("translated strings"), "locale_admin"); + menu("admin/locale/$key/untranslated", t("untranslated strings"), "locale_admin"); } } } diff --git a/modules/node.module b/modules/node.module index 65714a1e3..45ff4dbb7 100644 --- a/modules/node.module +++ b/modules/node.module @@ -1,14 +1,13 @@ <?php // $Id$ -function node_help($section = "admin/node/help") { +function node_help($section = "admin/help#node") { global $mod; $output = ""; switch ($section) { - case 'admin/help': - case 'admin/node/help': + case 'admin/help#node': $output .= "<h3>Nodes</h3>"; $output .= "<p>The core of the Drupal system is the node. All of the contents of the system are placed in nodes, or extensions of nodes."; $output .= "A base node contains:<dl>"; @@ -560,14 +559,14 @@ function node_link($type, $node = 0, $main = 0) { } if ($type == "system") { - menu("node/add", t("create content"), NULL, NULL, 1); + menu("node/add", t("create content"), NULL, 1); if (user_access("administer nodes")) { - menu("admin/node", t("content"), "node_admin", node_help("admin/node")); - menu("admin/node/search", t("search"), "node_admin", node_help("admin/node/search"), 8); - menu("admin/node/help", t("help"), "node_help", NULL, 9); - menu("admin/node/edit", t("edit post"), "node_admin", NULL, 0, 1); - menu("admin/node/settings", t("settings"), "node_admin", node_help("admin/node/settings"), 8); + menu("admin/node", t("content"), "node_admin"); + menu("admin/node/search", t("search"), "node_admin", 8); + menu("admin/node/help", t("help"), "node_help", 9); + menu("admin/node/edit", t("edit post"), "node_admin", 0, 1); + menu("admin/node/settings", t("settings"), "node_admin", 8); } } diff --git a/modules/node/node.module b/modules/node/node.module index 65714a1e3..45ff4dbb7 100644 --- a/modules/node/node.module +++ b/modules/node/node.module @@ -1,14 +1,13 @@ <?php // $Id$ -function node_help($section = "admin/node/help") { +function node_help($section = "admin/help#node") { global $mod; $output = ""; switch ($section) { - case 'admin/help': - case 'admin/node/help': + case 'admin/help#node': $output .= "<h3>Nodes</h3>"; $output .= "<p>The core of the Drupal system is the node. All of the contents of the system are placed in nodes, or extensions of nodes."; $output .= "A base node contains:<dl>"; @@ -560,14 +559,14 @@ function node_link($type, $node = 0, $main = 0) { } if ($type == "system") { - menu("node/add", t("create content"), NULL, NULL, 1); + menu("node/add", t("create content"), NULL, 1); if (user_access("administer nodes")) { - menu("admin/node", t("content"), "node_admin", node_help("admin/node")); - menu("admin/node/search", t("search"), "node_admin", node_help("admin/node/search"), 8); - menu("admin/node/help", t("help"), "node_help", NULL, 9); - menu("admin/node/edit", t("edit post"), "node_admin", NULL, 0, 1); - menu("admin/node/settings", t("settings"), "node_admin", node_help("admin/node/settings"), 8); + menu("admin/node", t("content"), "node_admin"); + menu("admin/node/search", t("search"), "node_admin", 8); + menu("admin/node/help", t("help"), "node_help", 9); + menu("admin/node/edit", t("edit post"), "node_admin", 0, 1); + menu("admin/node/settings", t("settings"), "node_admin", 8); } } diff --git a/modules/page.module b/modules/page.module index d7bdc3a3b..0dd848996 100644 --- a/modules/page.module +++ b/modules/page.module @@ -1,12 +1,11 @@ <?php // $Id$ -function page_help($section = "admin/page/help") { +function page_help($section = "admin/help#page") { $output = ""; switch ($section) { - case 'admin/help': - case 'admin/page/help': + case 'admin/help#page': $output .= "<p>The page module is used to create a <i>static page</i>. Unlike a story, a static page is a persistent web page on your site which usually shortcuts the typical lifecycle of user generated content (i.e. submit -> moderate -> post -> comment). A static page is usually linked from the main navigation bar, using whatever text the author wishes. To create a static page without this navigation link, simply skip the link text field.</p>"; $output .= "<p>Site pages, unlike many other forms of Drupal content, may be made of PHP code in addition to HTML and text. All Drupal objects and functions are available to a site administrator.</p>"; $output = t($output); @@ -90,7 +89,7 @@ function page_link($type) { if ($type == "system") { if (user_access("maintain static pages")) { - menu("node/add/page", t("static page"), "page_page", NULL, 0); + menu("node/add/page", t("static page"), "page_page", 0); } } diff --git a/modules/page/page.module b/modules/page/page.module index d7bdc3a3b..0dd848996 100644 --- a/modules/page/page.module +++ b/modules/page/page.module @@ -1,12 +1,11 @@ <?php // $Id$ -function page_help($section = "admin/page/help") { +function page_help($section = "admin/help#page") { $output = ""; switch ($section) { - case 'admin/help': - case 'admin/page/help': + case 'admin/help#page': $output .= "<p>The page module is used to create a <i>static page</i>. Unlike a story, a static page is a persistent web page on your site which usually shortcuts the typical lifecycle of user generated content (i.e. submit -> moderate -> post -> comment). A static page is usually linked from the main navigation bar, using whatever text the author wishes. To create a static page without this navigation link, simply skip the link text field.</p>"; $output .= "<p>Site pages, unlike many other forms of Drupal content, may be made of PHP code in addition to HTML and text. All Drupal objects and functions are available to a site administrator.</p>"; $output = t($output); @@ -90,7 +89,7 @@ function page_link($type) { if ($type == "system") { if (user_access("maintain static pages")) { - menu("node/add/page", t("static page"), "page_page", NULL, 0); + menu("node/add/page", t("static page"), "page_page", 0); } } diff --git a/modules/path.module b/modules/path.module index 3dc569462..98ac778b8 100644 --- a/modules/path.module +++ b/modules/path.module @@ -102,7 +102,7 @@ function path_form($edit = "", $error = "") { return form($form); } -function path_help($section = "admin/path/help") { +function path_help($section = "admin/help#path") { $output = ""; switch ($section) { @@ -115,7 +115,7 @@ function path_help($section = "admin/path/help") { case "admin/path/add": $output = t("Enter the path you wish to create the alias for, followed by the name of the new alias. Each path can be associated with only one alias."); break; - case "admin/path/help": + case "admin/help#path": $output .= "<h3>Background</h3><p>URL aliasing gives users the ability to have control over all Drupal paths. This functionality will integrate seamlessly into node forms and also provide the administrator an interface to view all aliases that have been created.</p><p>Aliases have a 1 to 1 relationship with their original Drupal URLs. In otherwards you cannot have an alias map to more than one path. Likewise, a Drupal URL can't be mapped to more than one alias.</p>"; $output .= "<h3>Permissions</h3><p>Two new permissions are introduced for aliasing URLs: <i>create url aliases</i> and <i>administer url aliases</i>.</p>"; $output .= "<ol>"; @@ -131,9 +131,9 @@ function path_help($section = "admin/path/help") { function path_link($type, $node = NULL) { if ($type == "system" && user_access("administer url aliases")) { - menu("admin/path", t("url aliasing"), "path_admin", path_help("admin/path"), 4); - menu("admin/path/add", t("new alias"), "path_admin", path_help("admin/path/add")); - menu("admin/path/help", t("help"), "path_admin", NULL, 9); + menu("admin/path", t("url aliasing"), "path_admin", 4); + menu("admin/path/add", t("new alias"), "path_admin"); + menu("admin/path/help", t("help"), "path_admin", 9); } } diff --git a/modules/path/path.module b/modules/path/path.module index 3dc569462..98ac778b8 100644 --- a/modules/path/path.module +++ b/modules/path/path.module @@ -102,7 +102,7 @@ function path_form($edit = "", $error = "") { return form($form); } -function path_help($section = "admin/path/help") { +function path_help($section = "admin/help#path") { $output = ""; switch ($section) { @@ -115,7 +115,7 @@ function path_help($section = "admin/path/help") { case "admin/path/add": $output = t("Enter the path you wish to create the alias for, followed by the name of the new alias. Each path can be associated with only one alias."); break; - case "admin/path/help": + case "admin/help#path": $output .= "<h3>Background</h3><p>URL aliasing gives users the ability to have control over all Drupal paths. This functionality will integrate seamlessly into node forms and also provide the administrator an interface to view all aliases that have been created.</p><p>Aliases have a 1 to 1 relationship with their original Drupal URLs. In otherwards you cannot have an alias map to more than one path. Likewise, a Drupal URL can't be mapped to more than one alias.</p>"; $output .= "<h3>Permissions</h3><p>Two new permissions are introduced for aliasing URLs: <i>create url aliases</i> and <i>administer url aliases</i>.</p>"; $output .= "<ol>"; @@ -131,9 +131,9 @@ function path_help($section = "admin/path/help") { function path_link($type, $node = NULL) { if ($type == "system" && user_access("administer url aliases")) { - menu("admin/path", t("url aliasing"), "path_admin", path_help("admin/path"), 4); - menu("admin/path/add", t("new alias"), "path_admin", path_help("admin/path/add")); - menu("admin/path/help", t("help"), "path_admin", NULL, 9); + menu("admin/path", t("url aliasing"), "path_admin", 4); + menu("admin/path/add", t("new alias"), "path_admin"); + menu("admin/path/help", t("help"), "path_admin", 9); } } diff --git a/modules/ping.module b/modules/ping.module index a791e44f6..b8c710787 100644 --- a/modules/ping.module +++ b/modules/ping.module @@ -1,12 +1,11 @@ <?php // $Id$ -function ping_help($section = "admin/ping/help") { +function ping_help($section = "admin/help#ping") { $output = ""; switch($section) { - case 'admin/help': - case 'admin/ping/help': + case 'admin/help#ping': $output .= "<p>Drupal can pings sites automatically to notify them that your site has changed. It can ping the following sites:</p>"; $output .= "<p>%weblogs, a web site that tracks and displays links to changed weblogs and news-oriented web sites. To get your Drupal site listed, weblogs.com must be informed about your site's updates. This is the job of the ping module and when installed, the administrator doesn't have to do anything to participate in the %weblogs system. The ping module automatically notifies weblogs.com when your site is updated. To do so, Drupal implements the %weblogs-XML.</p>"; $output .= "<p>%weblogs-RSS, a web site that tracks and displays links to recently changed RSS feeds in XML format. To get your Drupal site listed, %weblogs-RSS must be informed about updates to your RSS feed. This is the job of the ping module and when installed, the administrator doesn't have to do anything to participate in the %weblogs-RSS-changes system. The ping module automatically notifies %weblogs-RSS when your site is updated.</p>"; diff --git a/modules/ping/ping.module b/modules/ping/ping.module index a791e44f6..b8c710787 100644 --- a/modules/ping/ping.module +++ b/modules/ping/ping.module @@ -1,12 +1,11 @@ <?php // $Id$ -function ping_help($section = "admin/ping/help") { +function ping_help($section = "admin/help#ping") { $output = ""; switch($section) { - case 'admin/help': - case 'admin/ping/help': + case 'admin/help#ping': $output .= "<p>Drupal can pings sites automatically to notify them that your site has changed. It can ping the following sites:</p>"; $output .= "<p>%weblogs, a web site that tracks and displays links to changed weblogs and news-oriented web sites. To get your Drupal site listed, weblogs.com must be informed about your site's updates. This is the job of the ping module and when installed, the administrator doesn't have to do anything to participate in the %weblogs system. The ping module automatically notifies weblogs.com when your site is updated. To do so, Drupal implements the %weblogs-XML.</p>"; $output .= "<p>%weblogs-RSS, a web site that tracks and displays links to recently changed RSS feeds in XML format. To get your Drupal site listed, %weblogs-RSS must be informed about updates to your RSS feed. This is the job of the ping module and when installed, the administrator doesn't have to do anything to participate in the %weblogs-RSS-changes system. The ping module automatically notifies %weblogs-RSS when your site is updated.</p>"; diff --git a/modules/poll.module b/modules/poll.module index ccfa3011b..72deda17e 100644 --- a/modules/poll.module +++ b/modules/poll.module @@ -137,12 +137,12 @@ function poll_form(&$node, &$help, &$error) { return $output; } -function poll_help($section = "admin/poll/help") { +function poll_help($section = "admin/help#poll") { $output = ""; switch ($section) { - case 'admin/poll/help': + case 'admin/help#poll': $output .= "<p>Users with the correct %permissions can create and/or vote on polls.</p>"; $output .= "<ul>"; $output .= "<li> To create a poll a user needs the \"create polls\" permission.</li>"; @@ -182,7 +182,7 @@ function poll_link($type, $node = 0, $main) { if ($type == "system") { if (user_access("create polls")) { - menu("node/add/poll", t("poll"), "poll_page", NULL, 0); + menu("node/add/poll", t("poll"), "poll_page", 0); } } else if ($type == "page" && user_access("access content")) { diff --git a/modules/poll/poll.module b/modules/poll/poll.module index ccfa3011b..72deda17e 100644 --- a/modules/poll/poll.module +++ b/modules/poll/poll.module @@ -137,12 +137,12 @@ function poll_form(&$node, &$help, &$error) { return $output; } -function poll_help($section = "admin/poll/help") { +function poll_help($section = "admin/help#poll") { $output = ""; switch ($section) { - case 'admin/poll/help': + case 'admin/help#poll': $output .= "<p>Users with the correct %permissions can create and/or vote on polls.</p>"; $output .= "<ul>"; $output .= "<li> To create a poll a user needs the \"create polls\" permission.</li>"; @@ -182,7 +182,7 @@ function poll_link($type, $node = 0, $main) { if ($type == "system") { if (user_access("create polls")) { - menu("node/add/poll", t("poll"), "poll_page", NULL, 0); + menu("node/add/poll", t("poll"), "poll_page", 0); } } else if ($type == "page" && user_access("access content")) { diff --git a/modules/queue.module b/modules/queue.module index 013e9471a..cc526ddd0 100644 --- a/modules/queue.module +++ b/modules/queue.module @@ -35,7 +35,7 @@ function queue_perm() { function queue_link($type) { if ($type == "system") { if (user_access("access submission queue")) { - menu("queue", t("view submissions"), "queue_page", NULL, 1); + menu("queue", t("view submissions"), "queue_page", 1); } } diff --git a/modules/search.module b/modules/search.module index 6f9e68b8d..bc2cded6f 100644 --- a/modules/search.module +++ b/modules/search.module @@ -1,12 +1,11 @@ <?php // $Id$ -function search_help($section = "admin/search/help") { +function search_help($section = "admin/help#search") { $output = ""; switch ($section) { - case 'admin/help': - case 'admin/search/help': + case 'admin/help#search': $output = "<b>Search guidelines</b>"; $output .= "<p>The search page allows you to search the web site's content. You can specify multiple words, and they will all be searched for. You can also use wildcards, so 'walk*' will match 'walk', 'walking', 'walker', 'walkable' and so on. Furthermore, searches are not case sensitive so searching for 'walk', 'Walk' or 'WALK' will yield exactly the same results.</p>"; $output .= "<b>Words excluded from the search</b>"; diff --git a/modules/search/search.module b/modules/search/search.module index 6f9e68b8d..bc2cded6f 100644 --- a/modules/search/search.module +++ b/modules/search/search.module @@ -1,12 +1,11 @@ <?php // $Id$ -function search_help($section = "admin/search/help") { +function search_help($section = "admin/help#search") { $output = ""; switch ($section) { - case 'admin/help': - case 'admin/search/help': + case 'admin/help#search': $output = "<b>Search guidelines</b>"; $output .= "<p>The search page allows you to search the web site's content. You can specify multiple words, and they will all be searched for. You can also use wildcards, so 'walk*' will match 'walk', 'walking', 'walker', 'walkable' and so on. Furthermore, searches are not case sensitive so searching for 'walk', 'Walk' or 'WALK' will yield exactly the same results.</p>"; $output .= "<b>Words excluded from the search</b>"; diff --git a/modules/statistics.module b/modules/statistics.module index 446b91f59..082861578 100644 --- a/modules/statistics.module +++ b/modules/statistics.module @@ -106,20 +106,20 @@ function statistics_link($type, $node = 0, $main = 0) { if ($type == "system") { if ((user_access("administer statistics module") || (user_access("administer statistics")))) { - menu("admin/statistics", t("statistics"), "statistics_admin", statistics_help("admin/statistics"), 6); - menu("admin/statistics/referrers", t("referrer log"), "statistics_admin", statistics_help("admin/statistics/referrers")); - menu("admin/statistics/referrers/internal", t("internal referrers only"), "statistics_admin", statistics_help("admin/statistics/referrers/internal")); - menu("admin/statistics/referrers/external", t("external referrers only"), "statistics_admin", statistics_help("admin/statistics/referrers/external")); - menu("admin/statistics/log", t("access log"), "statistics_admin", statistics_help("admin/statistics/log")); - menu("admin/statistics/log/node", t("track node"), "statistics_admin", statistics_help("admin/statistics/log/node"), 0, 1); //hidden - menu("admin/statistics/log/user", t("track user"), "statistics_admin", statistics_help("admin/statistics/log/user"), 0, 1); //hidden - menu("admin/statistics/log/host", t("track host"), "statistics_admin", statistics_help("admin/statistics/log/host"), 0, 1); //hidden - menu("admin/statistics/top nodes page", t("configure 'top nodes' page"), "statistics_admin", statistics_help("admin/statistics/top nodes page"), 5); - menu("admin/statistics/help", t("help"), "statistics_help", NULL, 9); + menu("admin/statistics", t("statistics"), "statistics_admin", 6); + menu("admin/statistics/referrers", t("referrer log"), "statistics_admin"); + menu("admin/statistics/referrers/internal", t("internal referrers only"), "statistics_admin"); + menu("admin/statistics/referrers/external", t("external referrers only"), "statistics_admin"); + menu("admin/statistics/log", t("access log"), "statistics_admin"); + menu("admin/statistics/log/node", t("track node"), "statistics_admin", 0, 1); //hidden + menu("admin/statistics/log/user", t("track user"), "statistics_admin", 0, 1); //hidden + menu("admin/statistics/log/host", t("track host"), "statistics_admin", 0, 1); //hidden + menu("admin/statistics/top nodes page", t("configure 'top nodes' page"), "statistics_admin", 5); + menu("admin/statistics/help", t("help"), "statistics_help", 9); // block configuration: - menu("admin/system/block/top nodes block", t("configure 'top nodes' block"), "statistics_admin", statistics_help("admin/system/block/top nodes/block"), 5); - menu("admin/system/block/whos online block", t("configure 'who is online' block"), "statistics_admin", statistics_help("admin/system/block/whos online block"), 5); + menu("admin/system/block/top nodes block", t("configure 'top nodes' block"), "statistics_admin", 5); + menu("admin/system/block/whos online block", t("configure 'who is online' block"), "statistics_admin", 5); } } @@ -127,12 +127,11 @@ function statistics_link($type, $node = 0, $main = 0) { } -function statistics_help($section = "admin/statistics/help") { +function statistics_help($section = "admin/help#statistics") { $output = ""; switch ($section) { - case 'admin/help': - case 'admin/statistics/help': + case 'admin/help#statistics': $output .= "<h3>Introduction</h3>"; $output .= "<p>The statistics.module keeps track of numerous statistics for your site but be warned, statistical collection does cause a little overhead, thus everything comes <b>disabled</b> by default.<p>"; $output .= "<p>The module counts how many times, and from where -- using HTTP referrer -- each of your nodes is viewed. Once we have that count the module can do the following with it:"; diff --git a/modules/statistics/statistics.module b/modules/statistics/statistics.module index 446b91f59..082861578 100644 --- a/modules/statistics/statistics.module +++ b/modules/statistics/statistics.module @@ -106,20 +106,20 @@ function statistics_link($type, $node = 0, $main = 0) { if ($type == "system") { if ((user_access("administer statistics module") || (user_access("administer statistics")))) { - menu("admin/statistics", t("statistics"), "statistics_admin", statistics_help("admin/statistics"), 6); - menu("admin/statistics/referrers", t("referrer log"), "statistics_admin", statistics_help("admin/statistics/referrers")); - menu("admin/statistics/referrers/internal", t("internal referrers only"), "statistics_admin", statistics_help("admin/statistics/referrers/internal")); - menu("admin/statistics/referrers/external", t("external referrers only"), "statistics_admin", statistics_help("admin/statistics/referrers/external")); - menu("admin/statistics/log", t("access log"), "statistics_admin", statistics_help("admin/statistics/log")); - menu("admin/statistics/log/node", t("track node"), "statistics_admin", statistics_help("admin/statistics/log/node"), 0, 1); //hidden - menu("admin/statistics/log/user", t("track user"), "statistics_admin", statistics_help("admin/statistics/log/user"), 0, 1); //hidden - menu("admin/statistics/log/host", t("track host"), "statistics_admin", statistics_help("admin/statistics/log/host"), 0, 1); //hidden - menu("admin/statistics/top nodes page", t("configure 'top nodes' page"), "statistics_admin", statistics_help("admin/statistics/top nodes page"), 5); - menu("admin/statistics/help", t("help"), "statistics_help", NULL, 9); + menu("admin/statistics", t("statistics"), "statistics_admin", 6); + menu("admin/statistics/referrers", t("referrer log"), "statistics_admin"); + menu("admin/statistics/referrers/internal", t("internal referrers only"), "statistics_admin"); + menu("admin/statistics/referrers/external", t("external referrers only"), "statistics_admin"); + menu("admin/statistics/log", t("access log"), "statistics_admin"); + menu("admin/statistics/log/node", t("track node"), "statistics_admin", 0, 1); //hidden + menu("admin/statistics/log/user", t("track user"), "statistics_admin", 0, 1); //hidden + menu("admin/statistics/log/host", t("track host"), "statistics_admin", 0, 1); //hidden + menu("admin/statistics/top nodes page", t("configure 'top nodes' page"), "statistics_admin", 5); + menu("admin/statistics/help", t("help"), "statistics_help", 9); // block configuration: - menu("admin/system/block/top nodes block", t("configure 'top nodes' block"), "statistics_admin", statistics_help("admin/system/block/top nodes/block"), 5); - menu("admin/system/block/whos online block", t("configure 'who is online' block"), "statistics_admin", statistics_help("admin/system/block/whos online block"), 5); + menu("admin/system/block/top nodes block", t("configure 'top nodes' block"), "statistics_admin", 5); + menu("admin/system/block/whos online block", t("configure 'who is online' block"), "statistics_admin", 5); } } @@ -127,12 +127,11 @@ function statistics_link($type, $node = 0, $main = 0) { } -function statistics_help($section = "admin/statistics/help") { +function statistics_help($section = "admin/help#statistics") { $output = ""; switch ($section) { - case 'admin/help': - case 'admin/statistics/help': + case 'admin/help#statistics': $output .= "<h3>Introduction</h3>"; $output .= "<p>The statistics.module keeps track of numerous statistics for your site but be warned, statistical collection does cause a little overhead, thus everything comes <b>disabled</b> by default.<p>"; $output .= "<p>The module counts how many times, and from where -- using HTTP referrer -- each of your nodes is viewed. Once we have that count the module can do the following with it:"; diff --git a/modules/story.module b/modules/story.module index f7e1c4bfc..7429b0a30 100644 --- a/modules/story.module +++ b/modules/story.module @@ -1,17 +1,17 @@ <?php // $Id$ -function story_help($section = "admin/story/help") { +function story_help($section = "admin/help#story") { $output = ""; switch ($section) { - case "admin/system/modules#description": + case 'admin/system/modules#description': $output = t("Enables users to submit stories, articles or similar content."); break; - case "admin/system/modules/story": + case 'admin/system/modules/story': $output = t("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/help#story': $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 %story-config 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."; $output = t($output, array("%story-config" => l(t("site configuration » modules » story"), "admin/system/modules/story"))); @@ -53,7 +53,7 @@ function story_link($type) { if ($type == "system") { if (user_access("create stories")) { - menu("node/add/story", t("story"), "story_page", NULL, 0); + menu("node/add/story", t("story"), "story_page", 0); } } diff --git a/modules/story/story.module b/modules/story/story.module index f7e1c4bfc..7429b0a30 100644 --- a/modules/story/story.module +++ b/modules/story/story.module @@ -1,17 +1,17 @@ <?php // $Id$ -function story_help($section = "admin/story/help") { +function story_help($section = "admin/help#story") { $output = ""; switch ($section) { - case "admin/system/modules#description": + case 'admin/system/modules#description': $output = t("Enables users to submit stories, articles or similar content."); break; - case "admin/system/modules/story": + case 'admin/system/modules/story': $output = t("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/help#story': $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 %story-config 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."; $output = t($output, array("%story-config" => l(t("site configuration » modules » story"), "admin/system/modules/story"))); @@ -53,7 +53,7 @@ function story_link($type) { if ($type == "system") { if (user_access("create stories")) { - menu("node/add/story", t("story"), "story_page", NULL, 0); + menu("node/add/story", t("story"), "story_page", 0); } } diff --git a/modules/system.module b/modules/system.module index 11680ee19..cc0860468 100644 --- a/modules/system.module +++ b/modules/system.module @@ -1,24 +1,25 @@ <?php // $Id$ -function system_help($section = "admin/system/help") { +function system_help($section = "admin/help#system") { global $base_url; $output = ""; switch ($section) { - case "admin/system": + case 'admin/system': $output = t("General configuration options for your site. Set up the name of the site, e-mail address used in mail-outs, clean URL options, caching, etc."); break; - case "admin/system/themes": + case 'admin/system/themes': $output = t("Select which themes are available to your users and specify the default theme."); break; - case "admin/system/modules": + case 'admin/system/modules': $output = t("Modules are plugins for Drupal that extend its core functionality. Here you can select which modules are enabled. On the left hand side click on the name of the module for their individual configurations. Once a module is enabled, you will need to grant permissions to users in user management."); break; - case "admin/system/filters": + case 'admin/system/filters': $output = t("Filters fit between the raw text in a node and the HTML output. They allow you to replace text selectively. Uses include automatic conversion of emoticons into graphics and filtering HTML content from users' submissions."); break; - case "admin/system/help": + case 'admin/help#system': + case 'admin/system/help': $output .= "<p>Drupal comes with system-wide defaults but the setting-module provides control over many Drupal preferences, behaviours including visual and operational settings.</p>"; $output .= "<h3><a id=\"cron\">Cron</a></h3>"; // Start of system_help_cron @@ -53,8 +54,8 @@ function system_link($type) { if ($type == "system") { if (user_access("administer site configuration")) { - menu("admin/system", t("configuration"), "system_admin", system_help("admin/system"), 3); - menu("admin/system/themes", t("themes"), "system_admin", system_help("admin/system/themes"), 2); + menu("admin/system", t("configuration"), "system_admin", 3); + menu("admin/system/themes", t("themes"), "system_admin", 2); foreach (theme_list(1) as $theme) { // NOTE: refresh the list because some themes might have been enabled/disabled. @@ -65,15 +66,15 @@ function system_link($type) { } } - menu("admin/system/modules", t("modules"), "system_admin", system_help("admin/system/modules"), 3); + menu("admin/system/modules", t("modules"), "system_admin", 3); foreach (module_list(1) as $name) { // NOTE: refresh the list because some modules might have been enabled/disabled. if (module_hook($name, "settings")) { - menu("admin/system/modules/$name", t($name), "system_admin", module_invoke($name, "help", "admin/system/modules/$name") ? module_invoke($name, "help", "admin/system/modules/$name") : module_invoke($name, "system", "admin_help")); + menu("admin/system/modules/$name", t($name), "system_admin"); } } - menu("admin/system/filters", t("filters"), "system_admin", system_help("admin/system/filters"), 4); - menu("admin/system/help", t("help"), "system_help", NULL, 9); + menu("admin/system/filters", t("filters"), "system_admin", 4); + menu("admin/system/help", t("help"), "system_help", 9); } } } diff --git a/modules/system/system.module b/modules/system/system.module index 11680ee19..cc0860468 100644 --- a/modules/system/system.module +++ b/modules/system/system.module @@ -1,24 +1,25 @@ <?php // $Id$ -function system_help($section = "admin/system/help") { +function system_help($section = "admin/help#system") { global $base_url; $output = ""; switch ($section) { - case "admin/system": + case 'admin/system': $output = t("General configuration options for your site. Set up the name of the site, e-mail address used in mail-outs, clean URL options, caching, etc."); break; - case "admin/system/themes": + case 'admin/system/themes': $output = t("Select which themes are available to your users and specify the default theme."); break; - case "admin/system/modules": + case 'admin/system/modules': $output = t("Modules are plugins for Drupal that extend its core functionality. Here you can select which modules are enabled. On the left hand side click on the name of the module for their individual configurations. Once a module is enabled, you will need to grant permissions to users in user management."); break; - case "admin/system/filters": + case 'admin/system/filters': $output = t("Filters fit between the raw text in a node and the HTML output. They allow you to replace text selectively. Uses include automatic conversion of emoticons into graphics and filtering HTML content from users' submissions."); break; - case "admin/system/help": + case 'admin/help#system': + case 'admin/system/help': $output .= "<p>Drupal comes with system-wide defaults but the setting-module provides control over many Drupal preferences, behaviours including visual and operational settings.</p>"; $output .= "<h3><a id=\"cron\">Cron</a></h3>"; // Start of system_help_cron @@ -53,8 +54,8 @@ function system_link($type) { if ($type == "system") { if (user_access("administer site configuration")) { - menu("admin/system", t("configuration"), "system_admin", system_help("admin/system"), 3); - menu("admin/system/themes", t("themes"), "system_admin", system_help("admin/system/themes"), 2); + menu("admin/system", t("configuration"), "system_admin", 3); + menu("admin/system/themes", t("themes"), "system_admin", 2); foreach (theme_list(1) as $theme) { // NOTE: refresh the list because some themes might have been enabled/disabled. @@ -65,15 +66,15 @@ function system_link($type) { } } - menu("admin/system/modules", t("modules"), "system_admin", system_help("admin/system/modules"), 3); + menu("admin/system/modules", t("modules"), "system_admin", 3); foreach (module_list(1) as $name) { // NOTE: refresh the list because some modules might have been enabled/disabled. if (module_hook($name, "settings")) { - menu("admin/system/modules/$name", t($name), "system_admin", module_invoke($name, "help", "admin/system/modules/$name") ? module_invoke($name, "help", "admin/system/modules/$name") : module_invoke($name, "system", "admin_help")); + menu("admin/system/modules/$name", t($name), "system_admin"); } } - menu("admin/system/filters", t("filters"), "system_admin", system_help("admin/system/filters"), 4); - menu("admin/system/help", t("help"), "system_help", NULL, 9); + menu("admin/system/filters", t("filters"), "system_admin", 4); + menu("admin/system/help", t("help"), "system_help", 9); } } } diff --git a/modules/taxonomy.module b/modules/taxonomy.module index 68d64b9ae..ff0b8a199 100644 --- a/modules/taxonomy.module +++ b/modules/taxonomy.module @@ -24,9 +24,9 @@ function taxonomy_perm() { function taxonomy_link($type, $node = NULL) { if ($type == "system") { if (user_access("administer taxonomy")) { - menu("admin/taxonomy", t("taxonomy"), "taxonomy_admin", taxonomy_help("admin/taxonomy"), 3); - menu("admin/taxonomy/add/vocabulary", t("create new vocabulary"), "taxonomy_admin", taxonomy_help("admin/taxonomy/add/vocabulary")); - menu("admin/taxonomy/help", t("help"), "taxonomy_admin", NULL, 9); + menu("admin/taxonomy", t("taxonomy"), "taxonomy_admin", 3); + menu("admin/taxonomy/add/vocabulary", t("create new vocabulary"), "taxonomy_admin"); + menu("admin/taxonomy/help", t("help"), "taxonomy_admin", 9); } } else if ($type == "taxonomy terms" && $node != NULL) { @@ -795,7 +795,7 @@ function taxonomy_admin() { return $output; } -function taxonomy_help($section = "admin/taxonomy/help") { +function taxonomy_help($section = "admin/help#taxonomy") { $output = ""; switch ($section) { @@ -808,7 +808,7 @@ function taxonomy_help($section = "admin/taxonomy/help") { case 'admin/taxonomy/add/vocabulary': $output = t("When you create a controlled vocabulary you are creating a set of terms to use for describing content (known as descriptors in indexing lingo). Drupal allows you to describe each node type (blog, story, etc.) using one or many of these terms. For simple implementations, you might create a set of categories without subcategories, similar to Slashdot.org's or Kuro5hin.org's sections. For more complex implementations, you might create a hierarchical list of categories."); break; - case 'admin/taxonomy/help': + case 'admin/help#taxonomy': $output .= "<h3>Background</h3><p>Taxonomy is the study of classification. Drupal's taxonomy module allows you to define categories which are used to classify content. The module supports hierarchical classification and association between terms, allowing for truly flexible information retrieval and classification. For more details about %classification-types and insight into the development of the <i>taxonomy.module</i>, see this %drupal-dis.</p>"; $output .= "<h3>An example taxonomy: food</h3><ul><li>Dairy<ul><li>Milk</li></ul></li><li>Drink<ul><li>Alchohol<ul><li>Beer</li><li>Wine</li></ul></li><li>Pop</li><li>Milk</li></ul></li><li>Meat<ul><li>Beef</li><li>Chicken</li><li>Lamb</li></ul></li><li>Spices<ul><li>Sugar</li></ul></li></ul>"; $output .= "<p><b>Notes</b></p><ul><li>The term <i>Milk</i> appears within both <i>Dairy</i> and <i>Drink</i>. This is an example of <i>multiple parents</i> for a term.</li><li>In Drupal the order of siblings (e.g. <i>Beef</i>, <i>Chicken</i>, <i>Lamb</i>) in a taxonomy may be controlled with the <i>weight</i> parameter.</li></ul>"; diff --git a/modules/taxonomy/taxonomy.module b/modules/taxonomy/taxonomy.module index 68d64b9ae..ff0b8a199 100644 --- a/modules/taxonomy/taxonomy.module +++ b/modules/taxonomy/taxonomy.module @@ -24,9 +24,9 @@ function taxonomy_perm() { function taxonomy_link($type, $node = NULL) { if ($type == "system") { if (user_access("administer taxonomy")) { - menu("admin/taxonomy", t("taxonomy"), "taxonomy_admin", taxonomy_help("admin/taxonomy"), 3); - menu("admin/taxonomy/add/vocabulary", t("create new vocabulary"), "taxonomy_admin", taxonomy_help("admin/taxonomy/add/vocabulary")); - menu("admin/taxonomy/help", t("help"), "taxonomy_admin", NULL, 9); + menu("admin/taxonomy", t("taxonomy"), "taxonomy_admin", 3); + menu("admin/taxonomy/add/vocabulary", t("create new vocabulary"), "taxonomy_admin"); + menu("admin/taxonomy/help", t("help"), "taxonomy_admin", 9); } } else if ($type == "taxonomy terms" && $node != NULL) { @@ -795,7 +795,7 @@ function taxonomy_admin() { return $output; } -function taxonomy_help($section = "admin/taxonomy/help") { +function taxonomy_help($section = "admin/help#taxonomy") { $output = ""; switch ($section) { @@ -808,7 +808,7 @@ function taxonomy_help($section = "admin/taxonomy/help") { case 'admin/taxonomy/add/vocabulary': $output = t("When you create a controlled vocabulary you are creating a set of terms to use for describing content (known as descriptors in indexing lingo). Drupal allows you to describe each node type (blog, story, etc.) using one or many of these terms. For simple implementations, you might create a set of categories without subcategories, similar to Slashdot.org's or Kuro5hin.org's sections. For more complex implementations, you might create a hierarchical list of categories."); break; - case 'admin/taxonomy/help': + case 'admin/help#taxonomy': $output .= "<h3>Background</h3><p>Taxonomy is the study of classification. Drupal's taxonomy module allows you to define categories which are used to classify content. The module supports hierarchical classification and association between terms, allowing for truly flexible information retrieval and classification. For more details about %classification-types and insight into the development of the <i>taxonomy.module</i>, see this %drupal-dis.</p>"; $output .= "<h3>An example taxonomy: food</h3><ul><li>Dairy<ul><li>Milk</li></ul></li><li>Drink<ul><li>Alchohol<ul><li>Beer</li><li>Wine</li></ul></li><li>Pop</li><li>Milk</li></ul></li><li>Meat<ul><li>Beef</li><li>Chicken</li><li>Lamb</li></ul></li><li>Spices<ul><li>Sugar</li></ul></li></ul>"; $output .= "<p><b>Notes</b></p><ul><li>The term <i>Milk</i> appears within both <i>Dairy</i> and <i>Drink</i>. This is an example of <i>multiple parents</i> for a term.</li><li>In Drupal the order of siblings (e.g. <i>Beef</i>, <i>Chicken</i>, <i>Lamb</i>) in a taxonomy may be controlled with the <i>weight</i> parameter.</li></ul>"; diff --git a/modules/throttle.module b/modules/throttle.module index dd11a0dfb..ebc44dc18 100644 --- a/modules/throttle.module +++ b/modules/throttle.module @@ -9,7 +9,7 @@ function throttle_perm() { return array("access throttle box"); } -function throttle_help($section = "admin/throttle/help") { +function throttle_help($section = "admin/help#throttle") { switch ($section) { case "admin/system/modules#description": @@ -17,7 +17,7 @@ function throttle_help($section = "admin/throttle/help") { break; case "admin/system/modules/throttle": return t("If your site gets popular, or comes under a \"Denial of Service\" (DOS) attack, your hardware might become overwhelmed. These settings allow you to \"slow down\" the access to your site. To use throttle you need to have the %access enabled. For Drupal to preform throttling it needs to do an extra database query. This extra query happens on page displays. <b>Auto-throttle probability limiter</b> tells Drupal to do this extra DB query once every \"x\" page displays, where \"x\" is the percentage. So if it is set to 10%, the default, then for every 100 web pages it displays, it will preform the extra query ten time. ", array("%access" => l(t("access log"), "admin/system/modules/statistics"))); - case "admin/throttle/help": + case "admin/help#throttle": $output .= "<h3>Introduction</h3><p>This Drupal module allows you to enable and configure the auto-throttle congestion control mechanism offered by the %stats-mod. The auto-throttle mechanism allows your site to automatically adapt to different server levels.</p>"; $output .= "<p>This module also adds a block that displays the current status of the throttle. You must have \"%throttle-block\" privileges to view the block. As a general rule of thumb, only site administrators should be granted access to this block.</p>"; $output .= "<p>The auto-throttle mechanism performs an extra database query in order to determine what the current throttle level should be. Fortunately the throttle can be tuned so these database queries only occur on a fraction of all pages geenrated by your site, reducing the overhead to an insignificant amount. Additionally, when the top-most throttle level is reached, all throttle queries are suspended for a configurable period of time. More detail follows.</p>"; diff --git a/modules/throttle/throttle.module b/modules/throttle/throttle.module index dd11a0dfb..ebc44dc18 100644 --- a/modules/throttle/throttle.module +++ b/modules/throttle/throttle.module @@ -9,7 +9,7 @@ function throttle_perm() { return array("access throttle box"); } -function throttle_help($section = "admin/throttle/help") { +function throttle_help($section = "admin/help#throttle") { switch ($section) { case "admin/system/modules#description": @@ -17,7 +17,7 @@ function throttle_help($section = "admin/throttle/help") { break; case "admin/system/modules/throttle": return t("If your site gets popular, or comes under a \"Denial of Service\" (DOS) attack, your hardware might become overwhelmed. These settings allow you to \"slow down\" the access to your site. To use throttle you need to have the %access enabled. For Drupal to preform throttling it needs to do an extra database query. This extra query happens on page displays. <b>Auto-throttle probability limiter</b> tells Drupal to do this extra DB query once every \"x\" page displays, where \"x\" is the percentage. So if it is set to 10%, the default, then for every 100 web pages it displays, it will preform the extra query ten time. ", array("%access" => l(t("access log"), "admin/system/modules/statistics"))); - case "admin/throttle/help": + case "admin/help#throttle": $output .= "<h3>Introduction</h3><p>This Drupal module allows you to enable and configure the auto-throttle congestion control mechanism offered by the %stats-mod. The auto-throttle mechanism allows your site to automatically adapt to different server levels.</p>"; $output .= "<p>This module also adds a block that displays the current status of the throttle. You must have \"%throttle-block\" privileges to view the block. As a general rule of thumb, only site administrators should be granted access to this block.</p>"; $output .= "<p>The auto-throttle mechanism performs an extra database query in order to determine what the current throttle level should be. Fortunately the throttle can be tuned so these database queries only occur on a fraction of all pages geenrated by your site, reducing the overhead to an insignificant amount. Additionally, when the top-most throttle level is reached, all throttle queries are suspended for a configurable period of time. More detail follows.</p>"; diff --git a/modules/tracker.module b/modules/tracker.module index d40079cb3..5b5a6a59c 100644 --- a/modules/tracker.module +++ b/modules/tracker.module @@ -1,11 +1,11 @@ <?php // $Id$ -function tracker_help($section = "admin/tracker/help") { +function tracker_help($section = "admin/help#tracker") { $output = ""; switch ($section) { - case 'admin/tracker/help': + case 'admin/help#tracer': $output = t("<p>The tracker module is a handy module for displaying the most recent posts. By following the <i>view recent posts</i> link in the user block, a user may quickly review all recent postings.</p>"); break; case 'admin/system/modules#description': @@ -22,7 +22,7 @@ function tracker_link($type) { if ($type == "system") { if (user_access("access content")) { - menu("tracker", t("recent posts"), "tracker_page", NULL, 1); + menu("tracker", t("recent posts"), "tracker_page", 1); } } diff --git a/modules/tracker/tracker.module b/modules/tracker/tracker.module index d40079cb3..5b5a6a59c 100644 --- a/modules/tracker/tracker.module +++ b/modules/tracker/tracker.module @@ -1,11 +1,11 @@ <?php // $Id$ -function tracker_help($section = "admin/tracker/help") { +function tracker_help($section = "admin/help#tracker") { $output = ""; switch ($section) { - case 'admin/tracker/help': + case 'admin/help#tracer': $output = t("<p>The tracker module is a handy module for displaying the most recent posts. By following the <i>view recent posts</i> link in the user block, a user may quickly review all recent postings.</p>"); break; case 'admin/system/modules#description': @@ -22,7 +22,7 @@ function tracker_link($type) { if ($type == "system") { if (user_access("access content")) { - menu("tracker", t("recent posts"), "tracker_page", NULL, 1); + menu("tracker", t("recent posts"), "tracker_page", 1); } } diff --git a/modules/user.module b/modules/user.module index 4c8daaa12..4d0d5a21b 100644 --- a/modules/user.module +++ b/modules/user.module @@ -496,26 +496,26 @@ function user_link($type) { if ($type == "system") { global $user; if ($user->uid) { - menu("user/edit", t("my account"), "user_page", NULL, 8); - menu("user/logout", t("log out"), "user_page", NULL, 10); + menu("user/edit", t("my account"), "user_page", 8); + menu("user/logout", t("log out"), "user_page", 10); } if (user_access("administer users")) { - menu("admin/user", t("accounts"), "user_admin", user_help("admin/user"), 2); - menu("admin/user/create", t("new user"), "user_admin", user_help("admin/user/create"), 1); - menu("admin/user/account", t("users"), "user_admin", user_help("admin/user/account"), 2); - menu("admin/user/access", t("access rules"), NULL, user_help("admin/user/access"), 3); - menu("admin/user/access/mail", t("by e-mail"), "user_admin", user_help("admin/user/access/mail")); - menu("admin/user/access/user", t("by name"), "user_admin", user_help("admin/user/access/user")); - menu("admin/user/role", t("roles"), "user_admin", user_help("admin/user/role"), 4); - menu("admin/user/permission", t("permissions"), "user_admin", user_help("admin/user/permission"), 5); - menu("admin/user/search", t("search"), "user_admin", user_help("admin/user/search"), 8); - menu("admin/user/help", t("help"), "user_help", NULL, 9); - menu("admin/user/edit", t("edit user account"), "user_admin", NULL, 0, 1); // hidden menu - menu("admin/user/account/1", t("blocked users"), "user_admin", user_help("admin/user/account/1"), 3); + menu("admin/user", t("accounts"), "user_admin", 2); + menu("admin/user/create", t("new user"), "user_admin", 1); + menu("admin/user/account", t("users"), "user_admin", 2); + menu("admin/user/access", t("access rules"), NULL, 3); + menu("admin/user/access/mail", t("by e-mail"), "user_admin"); + menu("admin/user/access/user", t("by name"), "user_admin"); + menu("admin/user/role", t("roles"), "user_admin", 4); + menu("admin/user/permission", t("permissions"), "user_admin", 5); + menu("admin/user/search", t("search"), "user_admin", 8); + menu("admin/user/help", t("help"), "user_help", 9); + menu("admin/user/edit", t("edit user account"), "user_admin", 0, 1); // hidden menu + menu("admin/user/account/1", t("blocked users"), "user_admin", 3); $i = 2; foreach (user_roles(1) as $key => $value) { - menu("admin/user/account/$i", t("users with role '%role'", array("%role" => $value)), "user_admin", user_help("admin/user/account/".$i++), 4); + menu("admin/user/account/$i", t("users with role '%role'", array("%role" => $value)), "user_admin", 4); } } } @@ -1195,7 +1195,7 @@ function user_page() { break; case "help": theme("header"); - theme("box", t("Distributed authentication"), user_help("user/help")); + theme("box", t("Distributed authentication"), user_help("user/help#user")); theme("footer"); break; default: @@ -1692,13 +1692,14 @@ function user_admin() { } } // the following functions comprise help for admins and developers -function user_help($section = "admin/user/help") { +function user_help($section = "admin/help#user") { $output = ""; switch ($section) { case 'admin/user': $output .= t("Drupal allows users to register, login, logout, maintain user profiles, etc. No participant can use his own name to post content until he signs up for a user account.<br />Click on either the \"username\" or \"edit account\" to edit a user's information."); break; + case 'admin/user/create': case 'admin/user/account/create': $output .= t("This web page allows the administrators to register a new users by hand.<br />Note:<ul><li>You cannot have a user where either the e-mail address or the username match another user in the system.</li></ul>"); break; @@ -1748,7 +1749,7 @@ function user_help($section = "admin/user/help") { case 'admin/system/modules/user': $output .= t("In order to use the full power of Drupal a visitor must sign up for an account. This page lets you setup how a user signs up, logs out, the guidelines from the system about user subscriptions, and the e-mails the system will send to the user."); break; - case 'user/help': + case 'user/help#user': $site = variable_get("site_name", "this website"); $output .= "<h3>Distributed authentication<a id=\"da\"></a></h3>"; @@ -1760,11 +1761,11 @@ function user_help($section = "admin/user/help") { foreach (module_list() as $module) { if (module_hook($module, "auth")) { $output .= "<h4><a id=\"$module\"></a>". module_invoke($module, "info", "name") ."</h4>"; - $output .= module_invoke($module, "help", "user/help"); + $output .= module_invoke($module, "help", "user/help#$module"); } } break; - case 'admin/user/help': + case 'admin/help#user': // Start of user_help_admin $output .= "<h3>Introduction</h3><p>Drupal offers a powerful access system that allows users to register, login, logout, maintain user profiles, etc. By using \"%user-role\" you can setup fine grained %user-permission allowing each role to do only what you want them to. Each user is assigned to a role. By default there are two roles \"anonymous\" - a user who has not logged in, and \"authorized\" a user who has signed up and who has been authorized. As anonymous users, participants suffer numerous disadvantages, for example they cannot sign their names to nodes, and their moderated posts beginning at a lower score.</p>"; diff --git a/modules/user/user.module b/modules/user/user.module index 4c8daaa12..4d0d5a21b 100644 --- a/modules/user/user.module +++ b/modules/user/user.module @@ -496,26 +496,26 @@ function user_link($type) { if ($type == "system") { global $user; if ($user->uid) { - menu("user/edit", t("my account"), "user_page", NULL, 8); - menu("user/logout", t("log out"), "user_page", NULL, 10); + menu("user/edit", t("my account"), "user_page", 8); + menu("user/logout", t("log out"), "user_page", 10); } if (user_access("administer users")) { - menu("admin/user", t("accounts"), "user_admin", user_help("admin/user"), 2); - menu("admin/user/create", t("new user"), "user_admin", user_help("admin/user/create"), 1); - menu("admin/user/account", t("users"), "user_admin", user_help("admin/user/account"), 2); - menu("admin/user/access", t("access rules"), NULL, user_help("admin/user/access"), 3); - menu("admin/user/access/mail", t("by e-mail"), "user_admin", user_help("admin/user/access/mail")); - menu("admin/user/access/user", t("by name"), "user_admin", user_help("admin/user/access/user")); - menu("admin/user/role", t("roles"), "user_admin", user_help("admin/user/role"), 4); - menu("admin/user/permission", t("permissions"), "user_admin", user_help("admin/user/permission"), 5); - menu("admin/user/search", t("search"), "user_admin", user_help("admin/user/search"), 8); - menu("admin/user/help", t("help"), "user_help", NULL, 9); - menu("admin/user/edit", t("edit user account"), "user_admin", NULL, 0, 1); // hidden menu - menu("admin/user/account/1", t("blocked users"), "user_admin", user_help("admin/user/account/1"), 3); + menu("admin/user", t("accounts"), "user_admin", 2); + menu("admin/user/create", t("new user"), "user_admin", 1); + menu("admin/user/account", t("users"), "user_admin", 2); + menu("admin/user/access", t("access rules"), NULL, 3); + menu("admin/user/access/mail", t("by e-mail"), "user_admin"); + menu("admin/user/access/user", t("by name"), "user_admin"); + menu("admin/user/role", t("roles"), "user_admin", 4); + menu("admin/user/permission", t("permissions"), "user_admin", 5); + menu("admin/user/search", t("search"), "user_admin", 8); + menu("admin/user/help", t("help"), "user_help", 9); + menu("admin/user/edit", t("edit user account"), "user_admin", 0, 1); // hidden menu + menu("admin/user/account/1", t("blocked users"), "user_admin", 3); $i = 2; foreach (user_roles(1) as $key => $value) { - menu("admin/user/account/$i", t("users with role '%role'", array("%role" => $value)), "user_admin", user_help("admin/user/account/".$i++), 4); + menu("admin/user/account/$i", t("users with role '%role'", array("%role" => $value)), "user_admin", 4); } } } @@ -1195,7 +1195,7 @@ function user_page() { break; case "help": theme("header"); - theme("box", t("Distributed authentication"), user_help("user/help")); + theme("box", t("Distributed authentication"), user_help("user/help#user")); theme("footer"); break; default: @@ -1692,13 +1692,14 @@ function user_admin() { } } // the following functions comprise help for admins and developers -function user_help($section = "admin/user/help") { +function user_help($section = "admin/help#user") { $output = ""; switch ($section) { case 'admin/user': $output .= t("Drupal allows users to register, login, logout, maintain user profiles, etc. No participant can use his own name to post content until he signs up for a user account.<br />Click on either the \"username\" or \"edit account\" to edit a user's information."); break; + case 'admin/user/create': case 'admin/user/account/create': $output .= t("This web page allows the administrators to register a new users by hand.<br />Note:<ul><li>You cannot have a user where either the e-mail address or the username match another user in the system.</li></ul>"); break; @@ -1748,7 +1749,7 @@ function user_help($section = "admin/user/help") { case 'admin/system/modules/user': $output .= t("In order to use the full power of Drupal a visitor must sign up for an account. This page lets you setup how a user signs up, logs out, the guidelines from the system about user subscriptions, and the e-mails the system will send to the user."); break; - case 'user/help': + case 'user/help#user': $site = variable_get("site_name", "this website"); $output .= "<h3>Distributed authentication<a id=\"da\"></a></h3>"; @@ -1760,11 +1761,11 @@ function user_help($section = "admin/user/help") { foreach (module_list() as $module) { if (module_hook($module, "auth")) { $output .= "<h4><a id=\"$module\"></a>". module_invoke($module, "info", "name") ."</h4>"; - $output .= module_invoke($module, "help", "user/help"); + $output .= module_invoke($module, "help", "user/help#$module"); } } break; - case 'admin/user/help': + case 'admin/help#user': // Start of user_help_admin $output .= "<h3>Introduction</h3><p>Drupal offers a powerful access system that allows users to register, login, logout, maintain user profiles, etc. By using \"%user-role\" you can setup fine grained %user-permission allowing each role to do only what you want them to. Each user is assigned to a role. By default there are two roles \"anonymous\" - a user who has not logged in, and \"authorized\" a user who has signed up and who has been authorized. As anonymous users, participants suffer numerous disadvantages, for example they cannot sign their names to nodes, and their moderated posts beginning at a lower score.</p>"; diff --git a/modules/watchdog.module b/modules/watchdog.module index 45971a7ca..86207a0ec 100644 --- a/modules/watchdog.module +++ b/modules/watchdog.module @@ -1,12 +1,11 @@ <?php // $Id$ -function watchdog_help($section = "admin/help") { +function watchdog_help($section = "admin/help#watchdog") { $output = ""; switch ($section) { - case 'admin/help': - case 'admin/watchdog/help': + case 'admin/help#watchdog': $output .= "<p>Watchdog module monitors your web site, capturing system events in a log to be reviewed by an authorized individual at a later time. The Watchdog log is simply a list of recorded events containing usage data, performance data, errors, warnings and operational information. It is vital to %watchdog on a regular basis as it is often the only way to tell what is going on.</p>"; $output .= "<p>To ease administration, the watchdog will automatically discard old log entries, %log-entry. Needs \"cron.php\" to discard the entries.</p>"; $output = t($output, array("%watchdog" => l(t("check the Watchdog report"), "admin/watchdog"), "%log-entry" => l(t("as configured"), "admin/system/modules/watchdog"))); @@ -50,14 +49,14 @@ function watchdog_perm() { function watchdog_link($type) { if ($type == "system") { if (user_access("administer watchdog")) { - menu("admin/watchdog", t("messages"), "watchdog_admin", watchdog_help("admin/watchdog"), 6); - menu("admin/watchdog/user", t("user"), "watchdog_admin", watchdog_help("admin/watchdog/user")); - menu("admin/watchdog/regular", t("regular"), "watchdog_admin", watchdog_help("admin/watchdog/regular")); - menu("admin/watchdog/special", t("special"), "watchdog_admin", watchdog_help("admin/watchdog/special")); - menu("admin/watchdog/warning", t("warning"), "watchdog_admin", watchdog_help("admin/watchdog/warning")); - menu("admin/watchdog/error", t("error"), "watchdog_admin", watchdog_help("admin/watchdog/error")); - menu("admin/watchdog/httpd", t("httpd"), "watchdog_admin", watchdog_help("admin/watchdog/httpd")); - menu("admin/watchdog/view", t("view details"), "watchdog_admin", NULL, 0, 1); // hidden menu + menu("admin/watchdog", t("messages"), "watchdog_admin", 6); + menu("admin/watchdog/user", t("user"), "watchdog_admin"); + menu("admin/watchdog/regular", t("regular"), "watchdog_admin"); + menu("admin/watchdog/special", t("special"), "watchdog_admin"); + menu("admin/watchdog/warning", t("warning"), "watchdog_admin"); + menu("admin/watchdog/error", t("error"), "watchdog_admin"); + menu("admin/watchdog/httpd", t("httpd"), "watchdog_admin"); + menu("admin/watchdog/view", t("view details"), "watchdog_admin", 0, 1); // hidden menu } } } diff --git a/modules/watchdog/watchdog.module b/modules/watchdog/watchdog.module index 45971a7ca..86207a0ec 100644 --- a/modules/watchdog/watchdog.module +++ b/modules/watchdog/watchdog.module @@ -1,12 +1,11 @@ <?php // $Id$ -function watchdog_help($section = "admin/help") { +function watchdog_help($section = "admin/help#watchdog") { $output = ""; switch ($section) { - case 'admin/help': - case 'admin/watchdog/help': + case 'admin/help#watchdog': $output .= "<p>Watchdog module monitors your web site, capturing system events in a log to be reviewed by an authorized individual at a later time. The Watchdog log is simply a list of recorded events containing usage data, performance data, errors, warnings and operational information. It is vital to %watchdog on a regular basis as it is often the only way to tell what is going on.</p>"; $output .= "<p>To ease administration, the watchdog will automatically discard old log entries, %log-entry. Needs \"cron.php\" to discard the entries.</p>"; $output = t($output, array("%watchdog" => l(t("check the Watchdog report"), "admin/watchdog"), "%log-entry" => l(t("as configured"), "admin/system/modules/watchdog"))); @@ -50,14 +49,14 @@ function watchdog_perm() { function watchdog_link($type) { if ($type == "system") { if (user_access("administer watchdog")) { - menu("admin/watchdog", t("messages"), "watchdog_admin", watchdog_help("admin/watchdog"), 6); - menu("admin/watchdog/user", t("user"), "watchdog_admin", watchdog_help("admin/watchdog/user")); - menu("admin/watchdog/regular", t("regular"), "watchdog_admin", watchdog_help("admin/watchdog/regular")); - menu("admin/watchdog/special", t("special"), "watchdog_admin", watchdog_help("admin/watchdog/special")); - menu("admin/watchdog/warning", t("warning"), "watchdog_admin", watchdog_help("admin/watchdog/warning")); - menu("admin/watchdog/error", t("error"), "watchdog_admin", watchdog_help("admin/watchdog/error")); - menu("admin/watchdog/httpd", t("httpd"), "watchdog_admin", watchdog_help("admin/watchdog/httpd")); - menu("admin/watchdog/view", t("view details"), "watchdog_admin", NULL, 0, 1); // hidden menu + menu("admin/watchdog", t("messages"), "watchdog_admin", 6); + menu("admin/watchdog/user", t("user"), "watchdog_admin"); + menu("admin/watchdog/regular", t("regular"), "watchdog_admin"); + menu("admin/watchdog/special", t("special"), "watchdog_admin"); + menu("admin/watchdog/warning", t("warning"), "watchdog_admin"); + menu("admin/watchdog/error", t("error"), "watchdog_admin"); + menu("admin/watchdog/httpd", t("httpd"), "watchdog_admin"); + menu("admin/watchdog/view", t("view details"), "watchdog_admin", 0, 1); // hidden menu } } } |