From cec03907dfcfa8d4fd03e5746e22e66c0fb638d3 Mon Sep 17 00:00:00 2001 From: Brion Vibber Date: Tue, 8 Sep 2009 17:42:02 +0000 Subject: [PATCH] Revert r55842 "Can now pass in element attributes other than just id to buildTable functions" Code won't actually work because $id can't be an array, per notes on http://www.mediawiki.org/wiki/Special:Code/MediaWiki/55842#c3882 --- includes/Xml.php | 3 --- 1 file changed, 3 deletions(-) diff --git a/includes/Xml.php b/includes/Xml.php index 4929a30d8f..c1b56544dd 100644 --- a/includes/Xml.php +++ b/includes/Xml.php @@ -699,14 +699,12 @@ class Xml { foreach( $headers as $id => $header ) { $attribs = array(); if ( is_string( $id ) ) $attribs['id'] = $id; - if ( is_array( $id ) ) $attribs = $id; $s .= Xml::element( 'th', $attribs, $header ); } } foreach( $rows as $id => $row ) { $attribs = array(); if ( is_string( $id ) ) $attribs['id'] = $id; - if ( is_array( $id ) ) $attribs = $id; $s .= Xml::buildTableRow( $attribs, $row ); } $s .= Xml::closeElement( 'table' ); @@ -723,7 +721,6 @@ class Xml { foreach( $cells as $id => $cell ) { $attribs = array(); if ( is_string( $id ) ) $attribs['id'] = $id; - if ( is_array( $id ) ) $attribs = $id; $s .= Xml::element( 'td', $attribs, $cell ); } $s .= Xml::closeElement( 'tr' ); -- 2.20.1