本文整理汇总了PHP中Xml::fieldset方法的典型用法代码示例。如果您正苦于以下问题:PHP Xml::fieldset方法的具体用法?PHP Xml::fieldset怎么用?PHP Xml::fieldset使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Xml
的用法示例。
在下文中一共展示了Xml::fieldset方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: show
function show()
{
global $wgOut, $wgUser;
// Header
$wgOut->setSubTitle(wfMsg('abusefilter-tools-subtitle'));
$wgOut->addWikiMsg('abusefilter-tools-text');
// Expression evaluator
$eval = '';
$eval .= AbuseFilter::buildEditBox('', 'wpTestExpr');
// Only let users with permission actually test it
if ($wgUser->isAllowed('abusefilter-modify')) {
$eval .= Xml::tags('p', null, Xml::element('input', array('type' => 'button', 'id' => 'mw-abusefilter-submitexpr', 'onclick' => 'doExprSubmit();', 'value' => wfMsg('abusefilter-tools-submitexpr'))));
$eval .= Xml::element('p', array('id' => 'mw-abusefilter-expr-result'), ' ');
}
$eval = Xml::fieldset(wfMsg('abusefilter-tools-expr'), $eval);
$wgOut->addHTML($eval);
// Associated script
$exprScript = file_get_contents(dirname(__FILE__) . '/tools.js');
$wgOut->addInlineScript($exprScript);
global $wgUser;
if ($wgUser->isAllowed('abusefilter-modify')) {
// Hacky little box to re-enable autoconfirmed if it got disabled
$rac = '';
$rac .= Xml::inputLabel(wfMsg('abusefilter-tools-reautoconfirm-user'), 'wpReAutoconfirmUser', 'reautoconfirm-user', 45);
$rac .= ' ';
$rac .= Xml::element('input', array('type' => 'button', 'id' => 'mw-abusefilter-reautoconfirmsubmit', 'onclick' => 'doReautoSubmit();', 'value' => wfMsg('abusefilter-tools-reautoconfirm-submit')));
$rac = Xml::fieldset(wfMsg('abusefilter-tools-reautoconfirm'), $rac);
$wgOut->addHTML($rac);
}
}
示例2: show
function show()
{
$out = $this->getOutput();
$user = $this->getUser();
// Header
$out->addWikiMsg('abusefilter-tools-text');
// Expression evaluator
$eval = '';
$eval .= AbuseFilter::buildEditBox('', 'wpTestExpr');
// Only let users with permission actually test it
if ($user->isAllowed('abusefilter-modify')) {
$eval .= Xml::tags('p', null, Xml::element('input', array('type' => 'button', 'id' => 'mw-abusefilter-submitexpr', 'value' => $this->msg('abusefilter-tools-submitexpr')->text())));
$eval .= Xml::element('p', array('id' => 'mw-abusefilter-expr-result'), ' ');
}
$eval = Xml::fieldset($this->msg('abusefilter-tools-expr')->text(), $eval);
$out->addHTML($eval);
$out->addModules('ext.abuseFilter.tools');
if ($user->isAllowed('abusefilter-modify')) {
// Hacky little box to re-enable autoconfirmed if it got disabled
$rac = '';
$rac .= Xml::inputLabel($this->msg('abusefilter-tools-reautoconfirm-user')->text(), 'wpReAutoconfirmUser', 'reautoconfirm-user', 45);
$rac .= ' ';
$rac .= Xml::element('input', array('type' => 'button', 'id' => 'mw-abusefilter-reautoconfirmsubmit', 'value' => $this->msg('abusefilter-tools-reautoconfirm-submit')->text()));
$rac = Xml::fieldset($this->msg('abusefilter-tools-reautoconfirm')->text(), $rac);
$out->addHTML($rac);
}
}
示例3: showList
function showList($conds = array('af_deleted' => 0), $optarray = array())
{
global $wgAbuseFilterCentralDB, $wgAbuseFilterIsCentral;
$output = '';
$output .= Xml::element('h2', null, $this->msg('abusefilter-list')->parse());
$pager = new AbuseFilterPager($this, $conds);
$deleted = $optarray['deleted'];
$hidedisabled = $optarray['hidedisabled'];
$scope = $optarray['scope'];
# Options form
$fields = array();
$fields['abusefilter-list-options-deleted'] = Xml::radioLabel($this->msg('abusefilter-list-options-deleted-show')->text(), 'deletedfilters', 'show', 'mw-abusefilter-deletedfilters-show', $deleted == 'show') . Xml::radioLabel($this->msg('abusefilter-list-options-deleted-hide')->text(), 'deletedfilters', 'hide', 'mw-abusefilter-deletedfilters-hide', $deleted == 'hide') . Xml::radioLabel($this->msg('abusefilter-list-options-deleted-only')->text(), 'deletedfilters', 'only', 'mw-abusefilter-deletedfilters-only', $deleted == 'only');
if (isset($wgAbuseFilterCentralDB) && !$wgAbuseFilterIsCentral) {
$fields['abusefilter-list-options-scope'] = Xml::radioLabel($this->msg('abusefilter-list-options-scope-local')->text(), 'rulescope', 'local', 'mw-abusefilter-rulescope-local', $scope == 'local') . Xml::radioLabel($this->msg('abusefilter-list-options-scope-global')->text(), 'rulescope', 'global', 'mw-abusefilter-rulescope-global', $scope == 'global');
}
$fields['abusefilter-list-options-disabled'] = Xml::checkLabel($this->msg('abusefilter-list-options-hidedisabled')->text(), 'hidedisabled', 'mw-abusefilter-disabledfilters-hide', $hidedisabled);
$fields['abusefilter-list-limit'] = $pager->getLimitSelect();
$options = Xml::buildForm($fields, 'abusefilter-list-options-submit');
$options .= Html::hidden('title', $this->getTitle()->getPrefixedText());
$options = Xml::tags('form', array('method' => 'get', 'action' => $this->getTitle()->getFullURL()), $options);
$options = Xml::fieldset($this->msg('abusefilter-list-options')->text(), $options);
$output .= $options;
if (isset($wgAbuseFilterCentralDB) && !$wgAbuseFilterIsCentral && $scope == 'global') {
$globalPager = new GlobalAbuseFilterPager($this, $conds);
$output .= $globalPager->getNavigationBar() . $globalPager->getBody() . $globalPager->getNavigationBar();
} else {
$output .= $pager->getNavigationBar() . $pager->getBody() . $pager->getNavigationBar();
}
$this->getOutput()->addHTML($output);
}
示例4: show
function show()
{
global $wgOut, $wgUser, $wgRequest;
AbuseFilter::disableConditionLimit();
if (!$wgUser->isAllowed('abusefilter-modify')) {
$wgOut->addWikiMsg('abusefilter-mustbeeditor');
return;
}
$this->loadParameters();
$wgOut->setPageTitle(wfMsg('abusefilter-test'));
$wgOut->addWikiMsg('abusefilter-test-intro', self::$mChangeLimit);
$output = '';
$output .= AbuseFilter::buildEditBox($this->mFilter, 'wpTestFilter') . "\n";
$output .= Xml::inputLabel(wfMsg('abusefilter-test-load-filter'), 'wpInsertFilter', 'mw-abusefilter-load-filter', 10, '') . ' ' . Xml::element('input', array('type' => 'button', 'value' => wfMsg('abusefilter-test-load'), 'id' => 'mw-abusefilter-load'));
$output = Xml::tags('div', array('id' => 'mw-abusefilter-test-editor'), $output);
$output .= Xml::tags('p', null, Xml::checkLabel(wfMsg('abusefilter-test-shownegative'), 'wpShowNegative', 'wpShowNegative', $this->mShowNegative));
// Selectory stuff
$selectFields = array();
$selectFields['abusefilter-test-user'] = Xml::input('wpTestUser', 45, $this->mTestUser);
$selectFields['abusefilter-test-period-start'] = Xml::input('wpTestPeriodStart', 45, $this->mTestPeriodStart);
$selectFields['abusefilter-test-period-end'] = Xml::input('wpTestPeriodEnd', 45, $this->mTestPeriodEnd);
$selectFields['abusefilter-test-page'] = Xml::input('wpTestPage', 45, $this->mTestPage);
$output .= Xml::buildForm($selectFields, 'abusefilter-test-submit');
$output .= Html::hidden('title', $this->getTitle('test')->getPrefixedText());
$output = Xml::tags('form', array('action' => $this->getTitle('test')->getLocalURL(), 'method' => 'post'), $output);
$output = Xml::fieldset(wfMsg('abusefilter-test-legend'), $output);
$wgOut->addHTML($output);
if ($wgRequest->wasPosted()) {
$this->doTest();
}
}
示例5: fooBarBaz
public function fooBarBaz($par)
{
global $wgBarBarBar, $wgUser;
if ($par) {
return;
}
$wgBarBarBar->dobar(Xml::fieldset(wfMessage('importinterwiki')->text()) . Xml::openElement('form', array('method' => 'post', 'action' => $par, 'id' => 'mw-import-interwiki-form')) . wfMessage('import-interwiki-text')->parse() . Xml::hidden('action', 'submit') . Xml::hidden('source', 'interwiki') . Xml::hidden('editToken', $wgUser->editToken()), 'secondArgument');
$foo = $par;
return $foo + $wgBarBarBar + $this->foo;
}
示例6: getAddForm
protected function getAddForm() {
return Xml::fieldset( wfMsg( 'premoderation-wl-addip-fieldset' ) ) .
Xml::openElement( 'form', array( 'id' => 'prem-wl-form', 'method' => 'post' ) ) .
'<table><tr><td>' . wfMsg( 'premoderation-private-ip' ) . '</td><td>' .
Xml::input( 'ip', 50, '', array( 'id' => 'prem-whitelist-addip' ) ) . '</td></tr>' .
'<tr><td>' . wfMsg( 'summary' ) . '</td><td>' . Xml::input( 'summary', 50, '',
array( 'id' => 'prem-summary' ) ) . '</td></tr><tr>' . '<td>' .
Xml::submitButton( wfMsg( 'htmlform-submit' ), array( 'id' => 'prem-wl-submit' ) ) .
'<input type="hidden" name="action" value="add" /></td></tr></table>' .
Xml::closeElement( 'form' ) . Xml::closeElement( 'fieldset' );
}
示例7: show
public function show($params)
{
global $wgOut;
$wgOut->setPageTitle(wfMsg('deletequeue'));
$this->loadSearch();
// Intro text
$wgOut->addWikiMsg('deletequeue-list-text');
// Search box
$searchBox = array();
// // Queue selector
$selector = Xml::openElement('select', array('name' => 'queue')) . "\n";
$queues = array('speedy', 'prod', 'deletediscuss');
$attribs = array('value' => '');
if (in_array($this->mQueue, $queues)) {
$attribs['selected'] = 'selected';
}
$selector .= Xml::element('option', $attribs, wfMsg('deletequeue-list-anyqueue'));
foreach ($queues as $queue) {
$attribs = array('value' => $queue);
if ($this->mQueue == $queue) {
$attribs['selected'] = 'selected';
}
$selector .= Xml::element('option', $attribs, wfMsg("deletequeue-queue-{$queue}"));
}
$selector .= Xml::closeElement('select');
$searchBox['deletequeue-list-queue'] = $selector;
$searchBox['deletequeue-list-status'] = Xml::checkLabel(wfMsg('deletequeue-list-expired'), 'expired', 'mw-dq-expired', $this->mExpired);
$searchBox = Xml::buildForm($searchBox, 'deletequeue-list-search');
$searchBox .= Html::Hidden('title', $this->getTitle()->getPrefixedText());
$searchBox = Xml::tags('form', array('action' => $this->getTitle()->getFullURL(), 'method' => 'get'), $searchBox);
$searchBox = Xml::fieldset(wfMsg('deletequeue-list-search-legend'), $searchBox);
$wgOut->addHTML($searchBox);
$conds = array('dq_active' => 1);
if ($this->mQueue) {
$conds['dq_queue'] = $this->mQueue;
}
if ($this->mExpired) {
$dbr = wfGetDB(DB_SLAVE);
$conds[] = 'dq_expiry<' . $dbr->addQuotes($dbr->timestamp(wfTimestampNow()));
}
// Headers
$body = '';
$headers = array('page', 'queue', 'votes', 'expiry', 'discusspage');
foreach ($headers as $header) {
$body .= Xml::element('th', null, wfMsg("deletequeue-list-header-{$header}")) . "\n";
}
$body = Xml::tags('tr', null, $body);
// The list itself
$pager = new DeleteQueuePager($conds);
$body .= $pager->getBody();
$body = Xml::tags('table', array('class' => 'wikitable'), $body);
$wgOut->addHTML($pager->getNavigationBar() . $body . $pager->getNavigationBar());
}
示例8: execute
function execute($subpage)
{
global $wgRequest, $wgOut;
$wgOut->setPageTitle('Wikitext Preview');
if ($wikitext = $wgRequest->getText('wikitext')) {
$wgOut->addHTML(Xml::fieldset('Wikitext preview', $wgOut->parse($wikitext)));
}
$f = Xml::textarea('wikitext', $wikitext);
$f .= Xml::submitButton('Preview wikitext');
$f .= Html::Hidden('title', $this->getTitle()->getPrefixedText());
$f = Xml::tags('form', array('method' => 'POST', 'action' => $this->getTitle()->getLocalURL()), $f);
$wgOut->addHTML(Xml::fieldset('Preview wikitext', $f));
}
示例9: buildForm
function buildForm()
{
$attrs = ['id' => 'mw-allmessages-form-lang', 'name' => 'lang'];
$msg = wfMessage('allmessages-language');
$langSelect = Xml::languageSelector($this->langcode, false, null, $attrs, $msg);
$out = Xml::openElement('form', ['method' => 'get', 'action' => $this->getConfig()->get('Script'), 'id' => 'mw-allmessages-form']) . Xml::fieldset($this->msg('allmessages-filter-legend')->text()) . Html::hidden('title', $this->getTitle()->getPrefixedText()) . Xml::openElement('table', ['class' => 'mw-allmessages-table']) . "\n" . '<tr>
<td class="mw-label">' . Xml::label($this->msg('allmessages-prefix')->text(), 'mw-allmessages-form-prefix') . "</td>\n\n\t\t\t<td class=\"mw-input\">" . Xml::input('prefix', 20, str_replace('_', ' ', $this->displayPrefix), ['id' => 'mw-allmessages-form-prefix']) . "</td>\n\n\t\t\t</tr>\n\t\t\t<tr>\n\n\t\t\t<td class='mw-label'>" . $this->msg('allmessages-filter')->escaped() . "</td>\n\n\t\t\t\t<td class='mw-input'>" . Xml::radioLabel($this->msg('allmessages-filter-unmodified')->text(), 'filter', 'unmodified', 'mw-allmessages-form-filter-unmodified', $this->filter === 'unmodified') . Xml::radioLabel($this->msg('allmessages-filter-all')->text(), 'filter', 'all', 'mw-allmessages-form-filter-all', $this->filter === 'all') . Xml::radioLabel($this->msg('allmessages-filter-modified')->text(), 'filter', 'modified', 'mw-allmessages-form-filter-modified', $this->filter === 'modified') . "</td>\n\n\t\t\t</tr>\n\t\t\t<tr>\n\n\t\t\t\t<td class=\"mw-label\">" . $langSelect[0] . "</td>\n\n\t\t\t\t<td class=\"mw-input\">" . $langSelect[1] . "</td>\n\n\t\t\t</tr>" . '<tr>
<td class="mw-label">' . Xml::label($this->msg('table_pager_limit_label')->text(), 'mw-table_pager_limit_label') . '</td>
<td class="mw-input">' . $this->getLimitSelect(['id' => 'mw-table_pager_limit_label']) . '</td>
<tr>
<td></td>
<td>' . Xml::submitButton($this->msg('allmessages-filter-submit')->text()) . "</td>\n\n\t\t\t</tr>" . Xml::closeElement('table') . $this->getHiddenFields(['title', 'prefix', 'filter', 'lang', 'limit']) . Xml::closeElement('fieldset') . Xml::closeElement('form');
return $out;
}
示例10: buildForm
function buildForm()
{
global $wgScript;
$languages = Language::getLanguageNames(false);
ksort($languages);
$out = Xml::openElement('form', array('method' => 'get', 'action' => $wgScript, 'id' => 'mw-allmessages-form')) . Xml::fieldset(wfMsg('allmessages-filter-legend')) . Xml::hidden('title', $this->getTitle()) . Xml::openElement('table', array('class' => 'mw-allmessages-table')) . "\n" . '<tr>
<td class="mw-label">' . Xml::label(wfMsg('allmessages-prefix'), 'mw-allmessages-form-prefix') . "</td>\n\n\t\t\t\t<td class=\"mw-input\">" . Xml::input('prefix', 20, str_replace('_', ' ', $this->prefix), array('id' => 'mw-allmessages-form-prefix')) . "</td>\n\n\t\t\t</tr>\n\t\t\t<tr>\n\n\t\t\t\t<td class='mw-label'>" . wfMsg('allmessages-filter') . "</td>\n\n\t\t\t\t<td class='mw-input'>" . Xml::radioLabel(wfMsg('allmessages-filter-unmodified'), 'filter', 'unmodified', 'mw-allmessages-form-filter-unmodified', $this->filter == 'unmodified' ? true : false) . Xml::radioLabel(wfMsg('allmessages-filter-all'), 'filter', 'all', 'mw-allmessages-form-filter-all', $this->filter == 'all' ? true : false) . Xml::radioLabel(wfMsg('allmessages-filter-modified'), 'filter', 'modified', 'mw-allmessages-form-filter-modified', $this->filter == 'modified' ? true : false) . "</td>\n\n\t\t\t</tr>\n\t\t\t<tr>\n\n\t\t\t\t<td class=\"mw-label\">" . Xml::label(wfMsg('allmessages-language'), 'mw-allmessages-form-lang') . "</td>\n\n\t\t\t\t<td class=\"mw-input\">" . Xml::openElement('select', array('id' => 'mw-allmessages-form-lang', 'name' => 'lang'));
foreach ($languages as $lang => $name) {
$selected = $lang == $this->langCode ? true : false;
$out .= Xml::option($lang . ' - ' . $name, $lang, $selected) . "\n";
}
$out .= Xml::closeElement('select') . "</td>\n\n\t\t\t</tr>\n\t\t\t<tr>\n\n\t\t\t\t<td></td>\n\t\t\t\t<td>" . Xml::submitButton(wfMsg('allmessages-filter-submit')) . "</td>\n\n\t\t\t</tr>" . Xml::closeElement('table') . $this->table->getHiddenFields(array('title', 'prefix', 'filter', 'lang')) . Xml::closeElement('fieldset') . Xml::closeElement('form');
return $out;
}
示例11: wrapForm
/**
* Wrap the form innards in an actual <form> element
* @param $html String HTML contents to wrap.
* @return String wrapped HTML.
*/
function wrapForm($html)
{
# Include a <fieldset> wrapper for style, if requested.
if ($this->mWrapperLegend !== false) {
$html = Xml::fieldset($this->mWrapperLegend, $html);
}
# Use multipart/form-data
$encType = $this->mUseMultipart ? 'multipart/form-data' : 'application/x-www-form-urlencoded';
# Attributes
$attribs = array('action' => $this->getTitle()->getFullURL($this->query), 'method' => $this->mMethod, 'class' => 'visualClear', 'enctype' => $encType);
if (!empty($this->mId)) {
$attribs['id'] = $this->mId;
}
return Html::rawElement('form', $attribs, $html);
}
示例12: showForm
/**
* Show the ViewUserLang form
* @param $target Mixed: user whose language and test wiki we're about to look up
*/
function showForm( $target ) {
global $wgScript, $wgOut;
$wgOut->addHTML(
Xml::fieldset( wfMsgHtml( 'wminc-viewuserlang' ) ) .
Xml::openElement( 'form', array( 'method' => 'get', 'action' => $wgScript ) ) .
Html::hidden( 'title', $this->getTitle()->getPrefixedText() ) .
"<p>" .
Xml::inputLabel( wfMsgHtml( 'wminc-viewuserlang-user' ), 'target', 'viewuserlang-username', 40, $target ) .
' ' .
Xml::submitButton( wfMsgHtml( 'wminc-viewuserlang-go' ) ) .
"</p>" .
Xml::closeElement( 'form' ) .
Xml::closeElement( 'fieldset' )
);
}
示例13: show
function show()
{
$filter = $this->mPage->mFilter;
global $wgUser, $wgRequest, $wgOut;
$sk = $wgUser->getSkin();
if (!$wgUser->isAllowed('abusefilter-revert')) {
$wgOut->permissionRequired('abusefilter-revert');
return;
}
$this->loadParameters();
if ($this->attemptRevert()) {
return;
}
$wgOut->addWikiMsg('abusefilter-revert-intro', $filter);
$wgOut->setPageTitle(wfMsg('abusefilter-revert-title', $filter));
// First, the search form.
$searchFields = array();
$searchFields['abusefilter-revert-filter'] = Xml::element('strong', null, $filter);
$searchFields['abusefilter-revert-periodstart'] = Xml::input('wpPeriodStart', 45, $this->origPeriodStart);
$searchFields['abusefilter-revert-periodend'] = Xml::input('wpPeriodEnd', 45, $this->origPeriodEnd);
$searchForm = Xml::buildForm($searchFields, 'abusefilter-revert-search');
$searchForm .= "\n" . Xml::hidden('submit', 1);
$searchForm = Xml::tags('form', array('action' => $this->getTitle("revert/{$filter}")->getLocalURL(), 'method' => 'POST'), $searchForm);
$searchForm = Xml::fieldset(wfMsg('abusefilter-revert-search-legend'), $searchForm);
$wgOut->addHTML($searchForm);
if ($this->mSubmit) {
// Add a summary of everything that will be reversed.
$wgOut->addWikiMsg('abusefilter-revert-preview-intro');
// Look up all of them.
$results = $this->doLookup();
$list = array();
foreach ($results as $result) {
$displayActions = array();
global $wgLang;
$displayActions = array_map(array('AbuseFilter', 'getActionDisplay'), $result['actions']);
$msg = wfMsgExt('abusefilter-revert-preview-item', array('parseinline', 'replaceafter'), array($wgLang->timeanddate($result['timestamp'], true), $sk->userLink($result['userid'], $result['user']), $result['action'], $sk->link($result['title']), $wgLang->commaList($displayActions), $sk->link(SpecialPage::getTitleFor('AbuseLog'), wfMsgNoTrans('abusefilter-log-detailslink'), array(), array('details' => $result['id']))));
$list[] = Xml::tags('li', null, $msg);
}
$wgOut->addHTML(Xml::tags('ul', null, implode("\n", $list)));
// Add a button down the bottom.
$confirmForm = Xml::hidden('editToken', $wgUser->editToken("abusefilter-revert-{$filter}")) . Xml::hidden('title', $this->getTitle("revert/{$filter}")->getPrefixedText()) . Xml::hidden('wpPeriodStart', $this->origPeriodStart) . Xml::hidden('wpPeriodEnd', $this->origPeriodEnd) . Xml::inputLabel(wfMsg('abusefilter-revert-reasonfield'), 'wpReason', 'wpReason', 45) . "\n" . Xml::submitButton(wfMsg('abusefilter-revert-confirm'));
$confirmForm = Xml::tags('form', array('action' => $this->getTitle("revert/{$filter}")->getLocalURL(), 'method' => 'post'), $confirmForm);
$wgOut->addHTML($confirmForm);
}
}
示例14: getHTML
public function getHTML()
{
global $wgRequest, $wgScript, $wgTitle;
$s = '';
$s .= Xml::fieldset(wfMsg('listuserrestrictions-legend'));
$s .= "<form action=\"{$wgScript}\">";
$s .= Xml::hidden('title', $wgTitle->getPrefixedDbKey());
$s .= Xml::label(wfMsgHtml('listuserrestrictions-type'), 'type') . ' ' . self::typeSelector('type', $wgRequest->getVal('type'), 'type');
$s .= ' ';
$s .= Xml::inputLabel(wfMsgHtml('listuserrestrictions-user'), 'user', 'user', false, $wgRequest->getVal('user'));
$s .= '<p>';
$s .= Xml::label(wfMsgHtml('listuserrestrictions-namespace'), 'namespace') . ' ' . Xml::namespaceSelector($wgRequest->getVal('namespace'), '', 'namespace');
$s .= ' ';
$s .= Xml::inputLabel(wfMsgHtml('listuserrestrictions-page'), 'page', 'page', false, $wgRequest->getVal('page'));
$s .= Xml::submitButton(wfMsg('listuserrestrictions-submit'));
$s .= "</p></form></fieldset>";
return $s;
}
示例15: showForm
protected function showForm() {
global $wgOut, $wgScript, $wgFeedbackNamespaces;
$form = Xml::openElement( 'form',
array( 'name' => 'reviewedpages', 'action' => $wgScript, 'method' => 'get' ) );
$form .= Xml::fieldset( wfMsg( 'ratedpages-leg' ) );
$form .= Html::hidden( 'title', $this->getTitle()->getPrefixedDBKey() );
$form .= ReaderFeedbackXML::getRatingTierMenu($this->tier) . ' ';
if( count($wgFeedbackNamespaces) > 1 ) {
$form .= ReaderFeedbackXML::getNamespaceMenu( $this->namespace ) . ' ';
}
if( count( ReaderFeedback::getFeedbackTags() ) > 0 ) {
$form .= ReaderFeedbackXML::getTagMenu( $this->tag );
}
$form .= " " . Xml::submitButton( wfMsg( 'go' ) ) .
Xml::closeElement( 'fieldset' ) .
Xml::closeElement( 'form' ) . "\n";
$wgOut->addHTML( $form );
}