diff --git a/ChangeLog b/ChangeLog index db7074ba9..b99385688 100644 --- a/ChangeLog +++ b/ChangeLog @@ -6,6 +6,8 @@ $Id$ $HeadURL: https://phpmyadmin.svn.sourceforge.net/svnroot/phpmyadmin/trunk/phpMyAdmin/ChangeLog $ 3.1.5.0 (not yet released) +- patch #2739001 [export] XML does not allow spaces in element names, + thanks to Derek Schaefer - drummingds1 3.1.4.0 (not yet released) + patch #1808339 [doc] Apache SSLOptions and StdEnvVars FAQ, diff --git a/libraries/export/xml.php b/libraries/export/xml.php index bc99eb006..4f2ce6f80 100644 --- a/libraries/export/xml.php +++ b/libraries/export/xml.php @@ -95,6 +95,7 @@ function PMA_exportHeader() { */ function PMA_exportDBHeader($db) { global $crlf; + $db = str_replace(' ', '_', $db); $head = '' . $crlf @@ -113,6 +114,7 @@ function PMA_exportDBHeader($db) { */ function PMA_exportDBFooter($db) { global $crlf; + $db = str_replace(' ', '_', $db); return PMA_exportOutputHandler('' . $crlf); } @@ -144,11 +146,13 @@ function PMA_exportDBCreate($db) { * @access public */ function PMA_exportData($db, $table, $crlf, $error_url, $sql_query) { + $db = str_replace(' ', '_', $db); + $table = str_replace(' ', '_', $table); $result = PMA_DBI_query($sql_query, null, PMA_DBI_QUERY_UNBUFFERED); $columns_cnt = PMA_DBI_num_fields($result); for ($i = 0; $i < $columns_cnt; $i++) { - $columns[$i] = stripslashes(PMA_DBI_field_name($result, $i)); + $columns[$i] = stripslashes(str_replace(' ', '_', PMA_DBI_field_name($result, $i))); } unset($i);