Thiemo Mättig (WMDE) has uploaded a new change for review.
https://gerrit.wikimedia.org/r/199844
Change subject: Replace Html::... with self::... in the Html class
..
Replace Html::... with self::... in the Html class
How cool is that, I can call a patch SelfHTML. ;-)
Change-Id: I17d36bc45a349c92715b88004aaae046d4f7be1c
---
M includes/Html.php
1 file changed, 24 insertions(+), 24 deletions(-)
git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core
refs/changes/44/199844/1
diff --git a/includes/Html.php b/includes/Html.php
index ed77729..6f22243 100644
--- a/includes/Html.php
+++ b/includes/Html.php
@@ -169,7 +169,7 @@
* @return string Raw HTML
*/
public static function linkButton( $contents, $attrs, $modifiers =
array() ) {
- return Html::element( 'a',
+ return self::element( 'a',
self::buttonAttributes( $attrs, $modifiers ),
$contents
);
@@ -191,7 +191,7 @@
public static function submitButton( $contents, $attrs, $modifiers =
array() ) {
$attrs['type'] = 'submit';
$attrs['value'] = $contents;
- return Html::element( 'input', self::buttonAttributes( $attrs,
$modifiers ) );
+ return self::element( 'input', self::buttonAttributes( $attrs,
$modifiers ) );
}
/**
@@ -460,7 +460,7 @@
*
* @par Numerical array
* @code
-* Html::element( 'em', array(
+* self::element( 'em', array(
* 'class' = array( 'foo', 'bar' )
* ) );
* // gives 'em class=foo bar/em'
@@ -468,7 +468,7 @@
*
* @par Associative array
* @code
-* Html::element( 'em', array(
+* self::element( 'em', array(
* 'class' = array( 'foo', 'bar', 'foo' = false, 'quux' =
true )
* ) );
* // gives 'em class=bar quux/em'
@@ -707,7 +707,7 @@
* @param array $value Value attribute
* @param string $type Type attribute
* @param array $attribs Associative array of miscellaneous extra
-* attributes, passed to Html::element()
+* attributes, passed to self::element()
* @return string Raw HTML
*/
public static function input( $name, $value = '', $type = 'text',
$attribs = array() ) {
@@ -715,7 +715,7 @@
$attribs['value'] = $value;
$attribs['name'] = $name;
if ( in_array( $type, array( 'text', 'search', 'email',
'password', 'number' ) ) ) {
- $attribs = Html::getTextInputAttributes( $attribs );
+ $attribs = self::getTextInputAttributes( $attribs );
}
return self::element( 'input', $attribs );
}
@@ -787,7 +787,7 @@
* @param string $name Name attribute
* @param string $value Value attribute
* @param array $attribs Associative array of miscellaneous extra
-* attributes, passed to Html::element()
+* attributes, passed to self::element()
* @return string Raw HTML
*/
public static function hidden( $name, $value, $attribs = array() ) {
@@ -803,7 +803,7 @@
* @param string $name Name attribute
* @param string $value Value attribute
* @param array $attribs Associative array of miscellaneous extra
-* attributes, passed to Html::element()
+* attributes, passed to self::element()
* @return string Raw HTML
*/
public static function textarea( $name, $value = '', $attribs = array()
) {
@@ -818,7 +818,7 @@
} else {
$spacedValue = $value;
}
- return self::element( 'textarea', Html::getTextInputAttributes(
$attribs ), $spacedValue );
+ return self::element( 'textarea', self::getTextInputAttributes(
$attribs ), $spacedValue );
}
/**
@@ -889,7 +889,7 @@
} elseif ( is_int( $nsId ) ) {
$nsName = $wgContLang-convertNamespace( $nsId
);
}
- $optionsHtml[] = Html::element(
+ $optionsHtml[] = self::element(
'option', array(
'disabled' = in_array( $nsId,
$params['disable'] ),
'value' = $nsId,
@@ -908,7 +908,7 @@
$ret = '';
if ( isset( $params['label'] ) ) {
- $ret .= Html::element(
+ $ret .= self::element(
'label', array(
'for' = isset( $selectAttribs['id'] )
? $selectAttribs['id'] : null,