summaryrefslogtreecommitdiff
path: root/actions/newmessage.php
diff options
context:
space:
mode:
authorSarven Capadisli <csarven@status.net>2009-10-31 16:14:38 +0100
committerSarven Capadisli <csarven@status.net>2009-10-31 16:14:38 +0100
commitf9bb95174b93de4ce28167eea21535a01394f71f (patch)
treea3c30607fe345c6c0ff9bfc5095cc16e9b67f7cd /actions/newmessage.php
parenta2302e5b76b827f906c5ded028e7c120c6200b76 (diff)
Added XHR for direct messages.
Diffstat (limited to 'actions/newmessage.php')
-rw-r--r--actions/newmessage.php17
1 files changed, 16 insertions, 1 deletions
diff --git a/actions/newmessage.php b/actions/newmessage.php
index eac4ab210..37fca1ca2 100644
--- a/actions/newmessage.php
+++ b/actions/newmessage.php
@@ -223,7 +223,22 @@ class NewmessageAction extends Action
}
$this->msg = $msg;
- $this->showPage();
+ if ($this->trimmed('ajax')) {
+ $this->startHTML('text/xml;charset=UTF-8');
+ $this->elementStart('head');
+ $this->element('title', null, _('New message'));
+ $this->elementEnd('head');
+ $this->elementStart('body');
+ if (common_logged_in()) {
+ $this->showNoticeForm();
+ }
+ $this->elementEnd('div');
+ $this->elementEnd('body');
+ $this->endHTML();
+ }
+ else {
+ $this->showPage();
+ }
}
function showPageNotice()