diff options
-rw-r--r-- | modules/blog.module | 11 | ||||
-rw-r--r-- | modules/blog/blog.module | 11 | ||||
-rw-r--r-- | modules/book.module | 10 | ||||
-rw-r--r-- | modules/book/book.module | 10 | ||||
-rw-r--r-- | modules/forum.module | 8 | ||||
-rw-r--r-- | modules/forum/forum.module | 8 | ||||
-rw-r--r-- | modules/node.module | 10 | ||||
-rw-r--r-- | modules/node/node.module | 10 | ||||
-rw-r--r-- | modules/page.module | 2 | ||||
-rw-r--r-- | modules/page/page.module | 2 | ||||
-rw-r--r-- | modules/story.module | 11 | ||||
-rw-r--r-- | modules/story/story.module | 11 |
12 files changed, 30 insertions, 74 deletions
diff --git a/modules/blog.module b/modules/blog.module index 5ee3470ce..f06b2117e 100644 --- a/modules/blog.module +++ b/modules/blog.module @@ -82,6 +82,9 @@ function blog_help($section) { case 'admin/system/modules/blog': $output .= t("A weblog is a running journal of a users ideas. Enter the minimum word count for a single entry, and the text displayed on the entry submission form"); break; + case 'node/add/blog': + $output = variable_get('blog_help', ''); + break; } return $output; @@ -159,16 +162,10 @@ function blog_validate(&$node) { return $error; } -function blog_form(&$node, &$help, &$error) { +function blog_form(&$node, &$error) { global $nid; $iid = $_GET["iid"]; - /* - ** Carry out some explanation or submission guidelines: - */ - - $help = variable_get("blog_help", ""); - if (empty($node->body)) { /* ** If the user clicked a "blog it" link, we load the data from the diff --git a/modules/blog/blog.module b/modules/blog/blog.module index 5ee3470ce..f06b2117e 100644 --- a/modules/blog/blog.module +++ b/modules/blog/blog.module @@ -82,6 +82,9 @@ function blog_help($section) { case 'admin/system/modules/blog': $output .= t("A weblog is a running journal of a users ideas. Enter the minimum word count for a single entry, and the text displayed on the entry submission form"); break; + case 'node/add/blog': + $output = variable_get('blog_help', ''); + break; } return $output; @@ -159,16 +162,10 @@ function blog_validate(&$node) { return $error; } -function blog_form(&$node, &$help, &$error) { +function blog_form(&$node, &$error) { global $nid; $iid = $_GET["iid"]; - /* - ** Carry out some explanation or submission guidelines: - */ - - $help = variable_get("blog_help", ""); - if (empty($node->body)) { /* ** If the user clicked a "blog it" link, we load the data from the diff --git a/modules/book.module b/modules/book.module index a53621846..2c182ba7a 100644 --- a/modules/book.module +++ b/modules/book.module @@ -180,7 +180,7 @@ function book_validate(&$node) { } } -function book_form(&$node, &$help, &$error) { +function book_form(&$node, &$error) { global $user; $op = $_POST["op"]; @@ -200,13 +200,6 @@ function book_form(&$node, &$help, &$error) { } } else { - - /* - ** Carry out some explanation or submission guidelines: - */ - - $help = book_node("description"); - /* ** If a regular user updates a book page, we create a new revision ** authored by that user: @@ -906,7 +899,6 @@ function book_help($section = "admin/help#book") { case 'admin/node/book/orphan': $output = t("Pages in a book are like a tree. As pages are edited, reorganized and removed, child pages might be left with no link to the rest of the book. Such pages are refered to as 'orphan pages'. On this page, administrators can review their books for orphans and reattach those pages as desired."); break; - } return $output; diff --git a/modules/book/book.module b/modules/book/book.module index a53621846..2c182ba7a 100644 --- a/modules/book/book.module +++ b/modules/book/book.module @@ -180,7 +180,7 @@ function book_validate(&$node) { } } -function book_form(&$node, &$help, &$error) { +function book_form(&$node, &$error) { global $user; $op = $_POST["op"]; @@ -200,13 +200,6 @@ function book_form(&$node, &$help, &$error) { } } else { - - /* - ** Carry out some explanation or submission guidelines: - */ - - $help = book_node("description"); - /* ** If a regular user updates a book page, we create a new revision ** authored by that user: @@ -906,7 +899,6 @@ function book_help($section = "admin/help#book") { case 'admin/node/book/orphan': $output = t("Pages in a book are like a tree. As pages are edited, reorganized and removed, child pages might be left with no link to the rest of the book. Such pages are refered to as 'orphan pages'. On this page, administrators can review their books for orphans and reattach those pages as desired."); break; - } return $output; diff --git a/modules/forum.module b/modules/forum.module index 2e18afe04..d5aa94832 100644 --- a/modules/forum.module +++ b/modules/forum.module @@ -181,7 +181,7 @@ function forum_validate(&$node) { } } -function forum_form(&$node, &$help, &$error) { +function forum_form(&$node, &$error) { if ($node->tid) { // editing $tid = $node->tid; @@ -191,9 +191,6 @@ function forum_form(&$node, &$help, &$error) { $tid = arg(3); } - // outputs the compose guidelines - $help = variable_get("forum_help", ""); - $output .= _taxonomy_term_select(t("Forum"), "tid", $tid, variable_get("forum_nav_vocabulary", ""), "", 0, "", variable_get("forum_containers", array())); if ($node->nid) { @@ -693,6 +690,9 @@ function forum_help($section = "admin/help#forum") { case 'admin/system/modules/forum': $output = _forum_message_taxonomy(); break; + case 'node/add/forum': + $output = variable_get('forum_help', ''); + break; } return $output; diff --git a/modules/forum/forum.module b/modules/forum/forum.module index 2e18afe04..d5aa94832 100644 --- a/modules/forum/forum.module +++ b/modules/forum/forum.module @@ -181,7 +181,7 @@ function forum_validate(&$node) { } } -function forum_form(&$node, &$help, &$error) { +function forum_form(&$node, &$error) { if ($node->tid) { // editing $tid = $node->tid; @@ -191,9 +191,6 @@ function forum_form(&$node, &$help, &$error) { $tid = arg(3); } - // outputs the compose guidelines - $help = variable_get("forum_help", ""); - $output .= _taxonomy_term_select(t("Forum"), "tid", $tid, variable_get("forum_nav_vocabulary", ""), "", 0, "", variable_get("forum_containers", array())); if ($node->nid) { @@ -693,6 +690,9 @@ function forum_help($section = "admin/help#forum") { case 'admin/system/modules/forum': $output = _forum_message_taxonomy(); break; + case 'node/add/forum': + $output = variable_get('forum_help', ''); + break; } return $output; diff --git a/modules/node.module b/modules/node.module index 0800cb94f..61ee57c88 100644 --- a/modules/node.module +++ b/modules/node.module @@ -1092,20 +1092,12 @@ function node_form($edit, $error = NULL) { // $error and $param must be passed by reference. $function = $edit->type ."_form"; if (function_exists($function)) { - $form .= $function($edit, $help, $error, $param); + $form .= $function($edit, $error, $param); } // Append extra node form: $form .= implode("", node_invoke_nodeapi($edit, "form post", $error)); - /* - ** Add the help text: - */ - - if ($help) { - $output .= "<p>$help</p>"; - } - $output .= "<div class=\"node-form\">"; /* diff --git a/modules/node/node.module b/modules/node/node.module index 0800cb94f..61ee57c88 100644 --- a/modules/node/node.module +++ b/modules/node/node.module @@ -1092,20 +1092,12 @@ function node_form($edit, $error = NULL) { // $error and $param must be passed by reference. $function = $edit->type ."_form"; if (function_exists($function)) { - $form .= $function($edit, $help, $error, $param); + $form .= $function($edit, $error, $param); } // Append extra node form: $form .= implode("", node_invoke_nodeapi($edit, "form post", $error)); - /* - ** Add the help text: - */ - - if ($help) { - $output .= "<p>$help</p>"; - } - $output .= "<div class=\"node-form\">"; /* diff --git a/modules/page.module b/modules/page.module index 37534ad49..99b2b8aae 100644 --- a/modules/page.module +++ b/modules/page.module @@ -123,7 +123,7 @@ function page_view($node, $main = 0, $page = 0) { return theme("node", $node, $main, $page); } -function page_form(&$node, &$help, &$error) { +function page_form(&$node, &$error) { if (function_exists("taxonomy_node_form")) { $output .= implode("", taxonomy_node_form("page", $node)); } diff --git a/modules/page/page.module b/modules/page/page.module index 37534ad49..99b2b8aae 100644 --- a/modules/page/page.module +++ b/modules/page/page.module @@ -123,7 +123,7 @@ function page_view($node, $main = 0, $page = 0) { return theme("node", $node, $main, $page); } -function page_form(&$node, &$help, &$error) { +function page_form(&$node, &$error) { if (function_exists("taxonomy_node_form")) { $output .= implode("", taxonomy_node_form("page", $node)); } diff --git a/modules/story.module b/modules/story.module index b441b1667..2c05c7838 100644 --- a/modules/story.module +++ b/modules/story.module @@ -16,6 +16,9 @@ function story_help($section = "admin/help#story") { $output .= "In <a href=\"%story-config\">administer » configuration » modules » story</a> 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" => url("admin/system/modules/story"))); break; + case 'node/add/story': + $output = variable_get('story_help', ''); + break; } return $output; @@ -73,13 +76,7 @@ function story_validate(&$node) { return $error; } -function story_form(&$node, &$help, &$error) { - - /* - ** Carry out some explanation or submission guidelines: - */ - - $help = variable_get("story_help", ""); +function story_form(&$node, &$error) { if (function_exists("taxonomy_node_form")) { $output .= implode("", taxonomy_node_form("story", $node)); diff --git a/modules/story/story.module b/modules/story/story.module index b441b1667..2c05c7838 100644 --- a/modules/story/story.module +++ b/modules/story/story.module @@ -16,6 +16,9 @@ function story_help($section = "admin/help#story") { $output .= "In <a href=\"%story-config\">administer » configuration » modules » story</a> 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" => url("admin/system/modules/story"))); break; + case 'node/add/story': + $output = variable_get('story_help', ''); + break; } return $output; @@ -73,13 +76,7 @@ function story_validate(&$node) { return $error; } -function story_form(&$node, &$help, &$error) { - - /* - ** Carry out some explanation or submission guidelines: - */ - - $help = variable_get("story_help", ""); +function story_form(&$node, &$error) { if (function_exists("taxonomy_node_form")) { $output .= implode("", taxonomy_node_form("story", $node)); |