diff --git a/ChangeLog b/ChangeLog index 3303cf099..03534c9cc 100755 --- a/ChangeLog +++ b/ChangeLog @@ -5,6 +5,11 @@ phpMyAdmin - Changelog $Id$ $Source$ +2003-08-11 Michal Cihar + * libraries/export/csv.php3, libraries/export/latex.php3, + libraries/export/xml.php3: Added some stripslashes to generate correct + exports. + 2003-08-10 Marc Delisle * server_status.php3: bug 786331, a 100,00% not internationalized, and align values for "More status variables" diff --git a/libraries/export/csv.php3 b/libraries/export/csv.php3 index 80961b3b7..7b3d6d8d6 100644 --- a/libraries/export/csv.php3 +++ b/libraries/export/csv.php3 @@ -121,10 +121,10 @@ function PMA_exportData($db, $table, $crlf, $error_url, $sql_query) { $schema_insert = ''; for ($i = 0; $i < $fields_cnt; $i++) { if ($enclosed == '') { - $schema_insert .= mysql_field_name($result, $i); + $schema_insert .= stripslashes(mysql_field_name($result, $i)); } else { $schema_insert .= $enclosed - . str_replace($enclosed, $escaped . $enclosed, mysql_field_name($result, $i)) + . str_replace($enclosed, $escaped . $enclosed, stripslashes(mysql_field_name($result, $i))) . $enclosed; } $schema_insert .= $separator; @@ -142,6 +142,7 @@ function PMA_exportData($db, $table, $crlf, $error_url, $sql_query) { $schema_insert .= $GLOBALS[$what . '_replace_null']; } else if ($row[$j] == '0' || $row[$j] != '') { + $row[$j] = stripslashes($row[$j]); // loic1 : always enclose fields if ($what == 'excel') { $row[$j] = ereg_replace("\015(\012)?", "\012", $row[$j]); diff --git a/libraries/export/latex.php3 b/libraries/export/latex.php3 index e2c5106fa..bf2b5a90c 100644 --- a/libraries/export/latex.php3 +++ b/libraries/export/latex.php3 @@ -124,7 +124,7 @@ function PMA_exportData($db, $table, $crlf, $error_url, $sql_query) { // show column names if (isset($GLOBALS['latex_showcolumns'])) { - $local_buffer = implode("\000", $columns); + $local_buffer = stripslashes(implode("\000", $columns)); for($k=0;$k' . htmlspecialchars($record[$columns[$i]]) + $buffer .= ' <' . $columns[$i] . '>' . htmlspecialchars(stripslashes($record[$columns[$i]])) . '' . $crlf; } }