From 57feeb566a0cb2c544545dbfc616437cae69b923 Mon Sep 17 00:00:00 2001 From: Craig Andrews Date: Fri, 11 Sep 2009 22:37:37 -0400 Subject: Add a parameter named 'inreplyto' to the 'notice/new' page, so urls can inclue 'inreplyto' id's. Also add 'inreplyto' to the urls sent in emails. --- lib/noticeform.php | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) (limited to 'lib/noticeform.php') diff --git a/lib/noticeform.php b/lib/noticeform.php index 1e3a45142..d1387b1b7 100644 --- a/lib/noticeform.php +++ b/lib/noticeform.php @@ -69,6 +69,12 @@ class NoticeForm extends Form var $user = null; + /** + * The notice being replied to + */ + + var $inreplyto = null; + /** * Constructor * @@ -77,12 +83,13 @@ class NoticeForm extends Form * @param string $content content to pre-fill */ - function __construct($out=null, $action=null, $content=null, $user=null) + function __construct($out=null, $action=null, $content=null, $user=null, $inreplyto) { parent::__construct($out); $this->action = $action; $this->content = $content; + $this->inreplyto = $inreplyto; if ($user) { $this->user = $user; @@ -161,7 +168,7 @@ class NoticeForm extends Form if ($this->action) { $this->out->hidden('notice_return-to', $this->action, 'returnto'); } - $this->out->hidden('notice_in-reply-to', $this->action, 'inreplyto'); + $this->out->hidden('notice_in-reply-to', $this->inreplyto, 'inreplyto'); } /** -- cgit v1.2.3-54-g00ecf From 7cd80b29c45c2255e32328dc8b4e8a19933aa645 Mon Sep 17 00:00:00 2001 From: Craig Andrews Date: Sat, 12 Sep 2009 17:06:46 -0400 Subject: NoticeForm's constructor's inreplyto argument should be optional (defaulting to null) --- lib/noticeform.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib/noticeform.php') diff --git a/lib/noticeform.php b/lib/noticeform.php index d1387b1b7..350e37db8 100644 --- a/lib/noticeform.php +++ b/lib/noticeform.php @@ -83,7 +83,7 @@ class NoticeForm extends Form * @param string $content content to pre-fill */ - function __construct($out=null, $action=null, $content=null, $user=null, $inreplyto) + function __construct($out=null, $action=null, $content=null, $user=null, $inreplyto=null) { parent::__construct($out); -- cgit v1.2.3-54-g00ecf