Commit 1a5fcacd authored by Dries's avatar Dries

- Committed part 3 of Michael's help system improvements: removed the $help

  parameter from the menu() function.
parent 92852753
......@@ -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);
}
}
......
......@@ -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);
}
}
......
......@@ -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);
}
}
......
<?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);
}
}
......
<?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);
}
}
......
......@@ -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);
}
}
......
......@@ -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);
}
}
......
......@@ -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>&trade;.</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>";
......
......@@ -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>";
......
......@@ -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>";
......
<?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);
}
}
......
<?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);
}
}
}
......
<?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);
}
}
}
......
<?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");
}
......
<?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");
}
......
......@@ -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>";
......
......@@ -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>";
......
......@@ -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>";
......
......@@ -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>";
......
......@@ -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);
}
}
......
......@@ -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");
}
......
<?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");
}
}
}
......
<?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");