diff options
Diffstat (limited to 'modules/blog.module')
-rw-r--r-- | modules/blog.module | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/modules/blog.module b/modules/blog.module index f8cdb7922..7e7662a4f 100644 --- a/modules/blog.module +++ b/modules/blog.module @@ -227,7 +227,6 @@ function blog_page_last() { function blog_form(&$node, &$help, &$error) { global $nid, $iid; - if (isset($node->body)) { /* @@ -260,6 +259,10 @@ function blog_form(&$node, &$help, &$error) { } } + if ($node->teaser) { + $output .= form_textarea(t("Teaser"), "teaser", $node->teaser, 60, 5, $error["teaser"]); + } + $output = form_textarea(t("Body"), "body", $node->body, 60, 15, $error["body"] ? $error["body"] : t("Allowed HTML tags") .": ". htmlspecialchars(variable_get("allowed_html", ""))); return $output; @@ -311,7 +314,12 @@ function blog_link($type, $node = 0) { } if ($type == "node" && $node->type == "blog") { - $links[] = "<a href=\"module.php?mod=blog&op=view&id=$node->uid\">". strtr(t("%a's blog"), array("%a" => $node->name)) ."</a>"; + if (blog_access("update", $node)) { + $links[] = "<a href=\"module.php?mod=node&op=edit&id=$node->nid\">". t("update this blog") ."</a>"; + } + else { + $links[] = "<a href=\"module.php?mod=blog&op=view&id=$node->uid\">". strtr(t("%a's blog"), array("%a" => $node->name)) ."</a>"; + } } return $links ? $links : array(); |