summaryrefslogtreecommitdiff
path: root/modules/comment/helpers/comment.php
diff options
context:
space:
mode:
authorTim Almdal <tnalmdal@shaw.ca>2009-01-24 17:26:47 +0000
committerTim Almdal <tnalmdal@shaw.ca>2009-01-24 17:26:47 +0000
commitcbff78daa8a642e1800916f92e43202857c3b677 (patch)
tree1cb8302d4da07fbb384d44d94644088c718c6339 /modules/comment/helpers/comment.php
parenteed57674f99621e5354a13543067e9556eb9c6d0 (diff)
Supply a form id on all forms. This id can be used by modules other
than the originating module to provide additional functionality to the form.
Diffstat (limited to 'modules/comment/helpers/comment.php')
-rw-r--r--modules/comment/helpers/comment.php5
1 files changed, 3 insertions, 2 deletions
diff --git a/modules/comment/helpers/comment.php b/modules/comment/helpers/comment.php
index 3fbf05e1..a3ad2a6a 100644
--- a/modules/comment/helpers/comment.php
+++ b/modules/comment/helpers/comment.php
@@ -70,7 +70,7 @@ class comment_Core {
}
static function get_add_form($item) {
- $form = new Forge("comments", "", "post");
+ $form = new Forge("comments", "", "post", array("id" => "gAdd_Comment_Form"));
$group = $form->group("add_comment")->label(t("Add comment"));
$group->input("name") ->label(t("Name")) ->id("gAuthor");
$group->input("email") ->label(t("Email (hidden)")) ->id("gEmail");
@@ -93,7 +93,8 @@ class comment_Core {
}
static function get_edit_form($comment) {
- $form = new Forge("comments/{$comment->id}?_method=put", "", "post");
+ $form = new Forge("comments/{$comment->id}?_method=put", "", "post",
+ array("id" => "gEdit_Comment_Form"));
$group = $form->group("edit_comment")->label(t("Edit comment"));
$group->input("name") ->label(t("Author")) ->id("gAuthor");
$group->input("email") ->label(t("Email (hidden)")) ->id("gEmail");