MediaWiki master
EditWatchlistNormalHTMLForm.php
Go to the documentation of this file.
1<?php
22
27 public function getLegend( $namespace ) {
28 $namespace = (int)substr( $namespace, 2 );
29
30 return $namespace == NS_MAIN
31 ? $this->msg( 'blanknamespace' )->text()
32 : $this->getContext()->getLanguage()->getFormattedNsText( $namespace );
33 }
34
35 public function displaySection(
36 $fields, $sectionName = '', $fieldsetIDPrefix = '', &$hasUserVisibleFields = false
37 ) {
38 return parent::displaySection( $fields, $sectionName, 'editwatchlist-', $hasUserVisibleFields );
39 }
40}
const NS_MAIN
Definition Defines.php:65
Extend OOUIHTMLForm purely so we can have a more sensible way of getting the section headers.
displaySection( $fields, $sectionName='', $fieldsetIDPrefix='', &$hasUserVisibleFields=false)
getLegend( $namespace)
Get a string to go in the "<legend>" of a section fieldset.
msg( $key,... $params)
Get a Message object with context set Parameters are the same as wfMessage()
getContext()
Get the base IContextSource object.
Compact stacked vertical format for forms, implemented using OOUI widgets.