forked from GNUsocial/gnu-social
Filling in missing endHTML calls for Action AJAX
This completes 1c6f9df80e
where a lot
of other functions were fixed (by conforming to startHTML and endHTML)
This commit is contained in:
@@ -147,7 +147,7 @@ class TrainAction extends Action
|
||||
$this->elementStart('body');
|
||||
$form->show();
|
||||
$this->elementEnd('body');
|
||||
$this->elementEnd('html');
|
||||
$this->endHTML();
|
||||
} else {
|
||||
common_redirect(common_local_url('spam'), 303);
|
||||
}
|
||||
|
@@ -94,7 +94,7 @@ class AnonDisfavorAction extends RedirectingAction
|
||||
$favor = new AnonFavorForm($this, $notice);
|
||||
$favor->show();
|
||||
$this->elementEnd('body');
|
||||
$this->elementEnd('html');
|
||||
$this->endHTML();
|
||||
} else {
|
||||
$this->returnToPrevious();
|
||||
}
|
||||
|
@@ -89,7 +89,7 @@ class AnonFavorAction extends RedirectingAction
|
||||
$disfavor = new AnonDisFavorForm($this, $notice);
|
||||
$disfavor->show();
|
||||
$this->elementEnd('body');
|
||||
$this->elementEnd('html');
|
||||
$this->endHTML();
|
||||
} else {
|
||||
$this->returnToPrevious();
|
||||
}
|
||||
|
@@ -115,7 +115,7 @@ class BookmarkforurlAction extends Action
|
||||
$bf = new BookmarkForm($this, $this->title, $this->url, null, null, $this->thumbnail);
|
||||
$bf->show();
|
||||
$this->elementEnd('body');
|
||||
$this->elementEnd('html');
|
||||
$this->endHTML();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@@ -149,7 +149,7 @@ class NewgroupmessageAction extends Action
|
||||
sprintf(_m('Direct message to %s sent.'),
|
||||
$this->group->nickname));
|
||||
$this->elementEnd('body');
|
||||
$this->elementEnd('html');
|
||||
$this->endHTML();
|
||||
} else {
|
||||
common_redirect($gm->url, 303);
|
||||
}
|
||||
|
@@ -226,7 +226,7 @@ class QnanewanswerAction extends Action
|
||||
$this->elementStart('body');
|
||||
$this->element('p', array('id' => 'error'), $msg);
|
||||
$this->elementEnd('body');
|
||||
$this->elementEnd('html');
|
||||
$this->endHTML();
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -252,7 +252,7 @@ class QnanewanswerAction extends Action
|
||||
$form->show();
|
||||
|
||||
$this->elementEnd('body');
|
||||
$this->elementEnd('html');
|
||||
$this->endHTML();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@@ -139,7 +139,7 @@ class SearchsubAction extends Action
|
||||
$unsubscribe = new SearchUnsubForm($this, $this->search);
|
||||
$unsubscribe->show();
|
||||
$this->elementEnd('body');
|
||||
$this->elementEnd('html');
|
||||
$this->endHTML();
|
||||
} else {
|
||||
$url = common_local_url('search',
|
||||
array('search' => $this->search));
|
||||
|
@@ -79,7 +79,7 @@ class SearchunsubAction extends SearchsubAction
|
||||
$subscribe = new SearchSubForm($this, $this->search);
|
||||
$subscribe->show();
|
||||
$this->elementEnd('body');
|
||||
$this->elementEnd('html');
|
||||
$this->endHTML();
|
||||
} else {
|
||||
$url = common_local_url('search',
|
||||
array('search' => $this->search));
|
||||
|
@@ -167,7 +167,7 @@ abstract class BaseMirrorAction extends Action
|
||||
$unsubscribe = new EditMirrorForm($this, $this->profile);
|
||||
$unsubscribe->show();
|
||||
$this->elementEnd('body');
|
||||
$this->elementEnd('html');
|
||||
$this->endHTML();
|
||||
} else {
|
||||
$url = common_local_url('mirrorsettings');
|
||||
common_redirect($url, 303);
|
||||
|
@@ -126,8 +126,7 @@ class MirrorSettingsAction extends SettingsAction
|
||||
function handle($args)
|
||||
{
|
||||
if ($this->boolean('ajax')) {
|
||||
header('Content-Type: text/html;charset=utf-8');
|
||||
$this->elementStart('html');
|
||||
$this->startHTML('text/xml;charset=utf-8');
|
||||
$this->elementStart('head');
|
||||
// TRANS: Title for page with form to add a mirror feed provider on.
|
||||
$this->element('title', null, _m('Provider add'));
|
||||
@@ -137,7 +136,7 @@ class MirrorSettingsAction extends SettingsAction
|
||||
$this->showAddFeedForm();
|
||||
|
||||
$this->elementEnd('body');
|
||||
$this->elementEnd('html');
|
||||
$this->endHTML();
|
||||
} else {
|
||||
return parent::handle($args);
|
||||
}
|
||||
|
@@ -139,7 +139,7 @@ class TagsubAction extends Action
|
||||
$unsubscribe = new TagUnsubForm($this, $this->tag);
|
||||
$unsubscribe->show();
|
||||
$this->elementEnd('body');
|
||||
$this->elementEnd('html');
|
||||
$this->endHTML();
|
||||
} else {
|
||||
$url = common_local_url('tag',
|
||||
array('tag' => $this->tag));
|
||||
|
@@ -79,7 +79,7 @@ class TagunsubAction extends TagsubAction
|
||||
$subscribe = new TagSubForm($this, $this->tag);
|
||||
$subscribe->show();
|
||||
$this->elementEnd('body');
|
||||
$this->elementEnd('html');
|
||||
$this->endHTML();
|
||||
} else {
|
||||
$url = common_local_url('tag',
|
||||
array('tag' => $this->tag));
|
||||
|
@@ -142,7 +142,7 @@ class YammeradminpanelAction extends AdminPanelAction
|
||||
$this->elementStart('body');
|
||||
$form->show();
|
||||
$this->elementEnd('body');
|
||||
$this->elementEnd('html');
|
||||
$this->endHTML();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@@ -72,6 +72,6 @@ class YammerauthAction extends AdminPanelAction
|
||||
$this->elementStart('body');
|
||||
$form->show();
|
||||
$this->elementEnd('body');
|
||||
$this->elementEnd('html');
|
||||
$this->endHTML();
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user