diff --git a/libraries/export/odt.php b/libraries/export/odt.php
index 1f4ee08bd2..49da5d0a76 100644
--- a/libraries/export/odt.php
+++ b/libraries/export/odt.php
@@ -222,12 +222,10 @@ if (isset($plugin_list)) {
''
. __('Dumping data for table') . ' ' . htmlspecialchars($table)
- . '';
- $GLOBALS['odt_buffer'] .=
- '';
- $GLOBALS['odt_buffer'] .=
- ''
+ . ''
+ . '';
// If required, get fields name at the first line
@@ -323,26 +321,26 @@ if (isset($plugin_list)) {
'';
/* Header */
- $GLOBALS['odt_buffer'] .= '';
- $GLOBALS['odt_buffer'] .= ''
+ $GLOBALS['odt_buffer'] .= ''
+ . ''
. '' . __('Column') . ''
- . '';
- $GLOBALS['odt_buffer'] .= ''
+ . ''
+ . ''
. '' . __('Type') . ''
- . '';
- $GLOBALS['odt_buffer'] .= ''
+ . ''
+ . ''
. '' . __('Null') . ''
- . '';
- $GLOBALS['odt_buffer'] .= ''
+ . ''
+ . ''
. '' . __('Default') . ''
- . '';
- $GLOBALS['odt_buffer'] .= '';
+ . ''
+ . '';
$columns = PMA_DBI_get_columns($db, $view);
foreach ($columns as $column) {
$GLOBALS['odt_buffer'] .= PMA_formatOneColumnDefinition($column);
$GLOBALS['odt_buffer'] .= '';
- } // end foreach
+ } // end foreach
$GLOBALS['odt_buffer'] .= '';
return true;
@@ -423,17 +421,17 @@ if (isset($plugin_list)) {
$GLOBALS['odt_buffer'] .= '';
/* Header */
- $GLOBALS['odt_buffer'] .= '';
- $GLOBALS['odt_buffer'] .= ''
+ $GLOBALS['odt_buffer'] .= ''
+ . ''
. '' . __('Column') . ''
- . '';
- $GLOBALS['odt_buffer'] .= ''
+ . ''
+ . ''
. '' . __('Type') . ''
- . '';
- $GLOBALS['odt_buffer'] .= ''
+ . ''
+ . ''
. '' . __('Null') . ''
- . '';
- $GLOBALS['odt_buffer'] .= ''
+ . ''
+ . ''
. '' . __('Default') . ''
. '';
if ($do_relation && $have_rel) {
@@ -457,6 +455,7 @@ if (isset($plugin_list)) {
$columns = PMA_DBI_get_columns($db, $table);
foreach ($columns as $column) {
+ $field_name = $column['Field'];
$GLOBALS['odt_buffer'] .= PMA_formatOneColumnDefinition($column);
if ($do_relation && $have_rel) {
@@ -505,7 +504,7 @@ if (isset($plugin_list)) {
}
}
$GLOBALS['odt_buffer'] .= '';
- } // end foreach
+ } // end foreach
$GLOBALS['odt_buffer'] .= '';
return true;
@@ -524,23 +523,23 @@ if (isset($plugin_list)) {
function PMA_getTriggers($db, $table)
{
$GLOBALS['odt_buffer'] .= '';
- $GLOBALS['odt_buffer'] .= '';
- $GLOBALS['odt_buffer'] .= '';
- $GLOBALS['odt_buffer'] .= ''
+ . ' table:name="' . htmlspecialchars($table) . '_triggers">'
+ . ''
+ . ''
+ . ''
. '' . __('Name') . ''
- . '';
- $GLOBALS['odt_buffer'] .= ''
+ . ''
+ . ''
. '' . __('Time') . ''
- . '';
- $GLOBALS['odt_buffer'] .= ''
+ . ''
+ . ''
. '' . __('Event') . ''
- . '';
- $GLOBALS['odt_buffer'] .= ''
+ . ''
+ . ''
. '' . __('Definition') . ''
- . '';
- $GLOBALS['odt_buffer'] .= '';
+ . ''
+ . '';
$triggers = PMA_DBI_get_triggers($db, $table);
@@ -625,12 +624,12 @@ if (isset($plugin_list)) {
$triggers = PMA_DBI_get_triggers($db, $table);
if ($triggers) {
$GLOBALS['odt_buffer'] .=
- ''
- . __('Triggers') . ' '
- . htmlspecialchars($table)
- . '';
- PMA_getTriggers($db, $table);
+ ''
+ . __('Triggers') . ' '
+ . htmlspecialchars($table)
+ . '';
+ PMA_getTriggers($db, $table);
}
break;
case 'create_view':
@@ -656,11 +655,11 @@ if (isset($plugin_list)) {
PMA_getTableDefStandIn($db, $table, $crlf);
} // end switch
- return PMA_exportOutputHandler($dump);
+ return true;
} // end of the 'PMA_exportStructure' function
/**
- * Formats the definition for one column
+ * Formats the definition for one column
*
* @param array $column info about this column
*
@@ -683,8 +682,8 @@ if (isset($plugin_list)) {
}
$definition .= ''
- . '' . htmlspecialchars($type) . ''
- . '';
+ . '' . htmlspecialchars($type) . ''
+ . '';
if (! isset($column['Default'])) {
if ($column['Null'] != 'NO') {
$column['Default'] = 'NULL';
@@ -695,10 +694,10 @@ if (isset($plugin_list)) {
$column['Default'] = $column['Default'];
}
$definition .= ''
- . ''
- . (($column['Null'] == '' || $column['Null'] == 'NO')
- ? __('No')
- : __('Yes'))
+ . ''
+ . (($column['Null'] == '' || $column['Null'] == 'NO')
+ ? __('No')
+ : __('Yes'))
. ''
. '';
$definition .= ''