* @param string $name Name attribute
* @param bool $checked Whether the checkbox is checked or not
* @param array $attribs Array of additional attributes
+ * @return string
*/
public static function check( $name, $checked = false, array $attribs = array() ) {
if ( isset( $attribs['value'] ) ) {
* @param string $name Name attribute
* @param bool $checked Whether the checkbox is checked or not
* @param array $attribs Array of additional attributes
+ * @return string
*/
public static function radio( $name, $checked = false, array $attribs = array() ) {
if ( isset( $attribs['value'] ) ) {
* @param string $label Contents of the label
* @param string $id ID of the element being labeled
* @param array $attribs Additional attributes
+ * @return string
*/
public static function label( $label, $id, array $attribs = array() ) {
$attribs += array(
* Get HTML for an info box with an icon.
*
* @param string $text Wikitext, get this with wfMessage()->plain()
- * @param string $icon Icon name, file in skins/common/images
+ * @param string $icon Path to icon file (used as 'src' attribute)
* @param string $alt Alternate text for the icon
* @param string $class Additional class name to add to the wrapper div
- * @param bool $useStylePath
*
* @return string
*/
- static function infoBox( $text, $icon, $alt, $class = false, $useStylePath = true ) {
- global $wgStylePath;
-
- if ( $useStylePath ) {
- $icon = $wgStylePath . '/common/images/' . $icon;
- }
-
+ static function infoBox( $text, $icon, $alt, $class = false ) {
$s = Html::openElement( 'div', array( 'class' => "mw-infobox $class" ) );
$s .= Html::openElement( 'div', array( 'class' => 'mw-infobox-left' ) ) .