summaryrefslogtreecommitdiff
path: root/actions/disfavor.php
diff options
context:
space:
mode:
Diffstat (limited to 'actions/disfavor.php')
-rw-r--r--actions/disfavor.php17
1 files changed, 13 insertions, 4 deletions
diff --git a/actions/disfavor.php b/actions/disfavor.php
index 6f4a07886..ef01e891f 100644
--- a/actions/disfavor.php
+++ b/actions/disfavor.php
@@ -64,9 +64,18 @@ class DisfavorAction extends Action {
return;
}
- # XXX: ajax response
-
- common_redirect(common_local_url('showfavorites',
- array('nickname' => $user->nickname)));
+ if ($this->boolean('ajax')) {
+ common_start_html('text/xml');
+ common_element_start('head');
+ common_element('title', _('Favor'));
+ common_element_end('head');
+ common_element_start('body');
+ common_favor_form($notice);
+ common_element_end('body');
+ common_element_end('html');
+ } else {
+ common_redirect(common_local_url('showfavorites',
+ array('nickname' => $user->nickname)));
+ }
}
} \ No newline at end of file