Merge pull request #1216 from ibennetch/4449
Bug 4449: Mediawiki export does not produce table header row; also fix related PHP warnings
This commit is contained in:
commit
d2c184a3c6
@ -2,6 +2,7 @@ phpMyAdmin - ChangeLog
|
||||
======================
|
||||
|
||||
4.2.4.0 (not yet released)
|
||||
- bug #4449 Mediawiki export does not produce table header row; also fix related PHP warnings
|
||||
|
||||
4.2.3.0 (2014-06-08)
|
||||
- bug #4423 Moving fields not working
|
||||
|
||||
@ -64,6 +64,7 @@ if (!defined('TESTSUITE')) {
|
||||
'htmlword_structure_or_data',
|
||||
'htmlword_null',
|
||||
'htmlword_columns',
|
||||
'mediawiki_headers',
|
||||
'mediawiki_structure_or_data',
|
||||
'mediawiki_caption',
|
||||
'pdf_report_title',
|
||||
|
||||
@ -200,6 +200,7 @@ class ExportMediawiki extends ExportPlugin
|
||||
$do_mime = false,
|
||||
$dates = false
|
||||
) {
|
||||
$output = '';
|
||||
switch($export_mode) {
|
||||
case 'create_table':
|
||||
$columns = $GLOBALS['dbi']->getColumns($db, $table);
|
||||
@ -217,12 +218,12 @@ class ExportMediawiki extends ExportPlugin
|
||||
. $this->_exportCRLF();
|
||||
|
||||
// Add the table name
|
||||
if ($GLOBALS['mediawiki_caption']) {
|
||||
if (isset($GLOBALS['mediawiki_caption'])) {
|
||||
$output .= "|+'''" . $table . "'''" . $this->_exportCRLF();
|
||||
}
|
||||
|
||||
// Add the table headers
|
||||
if ($GLOBALS['mediawiki_headers']) {
|
||||
if (isset($GLOBALS['mediawiki_headers'])) {
|
||||
$output .= "|- style=\"background:#ffdead;\"" . $this->_exportCRLF();
|
||||
$output .= "! style=\"background:#ffffff\" | "
|
||||
. $this->_exportCRLF();
|
||||
@ -293,12 +294,12 @@ class ExportMediawiki extends ExportPlugin
|
||||
. $this->_exportCRLF();
|
||||
|
||||
// Add the table name
|
||||
if ($GLOBALS['mediawiki_caption']) {
|
||||
if (isset($GLOBALS['mediawiki_caption'])) {
|
||||
$output .= "|+'''" . $table . "'''" . $this->_exportCRLF();
|
||||
}
|
||||
|
||||
// Add the table headers
|
||||
if ($GLOBALS['mediawiki_headers']) {
|
||||
if (isset($GLOBALS['mediawiki_headers'])) {
|
||||
// Get column names
|
||||
$column_names = $GLOBALS['dbi']->getColumnNames($db, $table);
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user