diff --git a/ChangeLog b/ChangeLog index 046dee130..73b055270 100755 --- a/ChangeLog +++ b/ChangeLog @@ -5,6 +5,18 @@ phpMyAdmin - Changelog $Id$ $Source$ +2003-11-03 Garvin Hicking + * Documentation.html, tbl_row_delete.php3, + libraries/display_tbl.lib.php3: + Bug #828290: Fixed "Execute stored bookmark". Also made some minor + tweaks to make PHP-Transformations with forms working again. Added + a limitation notice on that to FAQ 3.8. Added an image to this action. + * libraries/display_tbl.lib.php3: Made multi-row delete working for + vertical browse mode. When executing a multi-row delete, keep the + last used display mode and other options. + * Documentation.html: Adjusted link to the link-section of our homepage. + Fixed typo. + 2003-11-03 Michal Cihar * lang/czech: Updated. * libraries/common.lib.php3: URI detection works with www-Sharp.Runtime diff --git a/Documentation.html b/Documentation.html index a128a8d6b..cc8bc75e5 100755 --- a/Documentation.html +++ b/Documentation.html @@ -1595,7 +1595,7 @@ $cfg['PmaAbsoluteUri'] = (!empty($_SERVER['HTTPS']) ? 'https' : 'http') . '://'

The HeaderFlipType can be set to 'css' or 'faked'. When using 'css' the rotation of the header for horizontalflipped is done via CSS. If - set to 'faked' PGP does the transformation for you, but of course this + set to 'faked' PHP does the transformation for you, but of course this does not look as good as CSS.

@@ -1971,7 +1971,7 @@ want the output stored in.


consult your <www.your-host.com>/<your-install-dir>/libraries/transformations/overview.php3 installation.

-


For a tutorial on how to effectively use transformations, see our Link section on the official phpMyAdmin-homepage.

+


For a tutorial on how to effectively use transformations, see our Link section on the official phpMyAdmin-homepage.


[2. Usage]

@@ -2150,7 +2150,7 @@ To create a new, empty mimetype please see libraries/transformations/template_ge


- Please have a look at our Link section on the official phpMyAdmin homepage for in-depth coverage of phpMyAdmin's features and/or interface. + Please have a look at our Link section on the official phpMyAdmin homepage for in-depth coverage of phpMyAdmin's features and/or interface.


@@ -2715,6 +2715,7 @@ To create a new, empty mimetype please see libraries/transformations/template_ge

The problem is that mysqldump creates invalid comments like this:

+
 -- MySQL dump 8.22
 --
@@ -2760,7 +2761,7 @@ To create a new, empty mimetype please see libraries/transformations/template_ge
 
 

[3.7] I have table with many (100+) fields and when I try to browse table - I get series of errors like "Warning: unable to parse url". How + I get series of errors like "Warning: unable to parse url". How can this be fixed?

@@ -2770,6 +2771,18 @@ To create a new, empty mimetype please see libraries/transformations/template_ge

+

+ [3.8] I cannot use (clickable) HTML-forms in fields where I put a MIME-Transformation onto! +

+

+ Due to a surrounding form-container (for multi-row delete checkboxes), no nested forms can be put inside the table where + phpMyAdmin displays the results. You can, however, use any form inside of a table if keep the parent form-container with + the target to tbl_row_delete.php3 and just put your own input-elements inside. If you use a custom submit input field, the + form will submit itself to the displaying page again, where you can validate the $HTTP_POST_VARS in a transformation. + + For a tutorial on how to effectively use transformations, see our Link section + on the official phpMyAdmin-homepage. +


[4. ISPs, multi-user installations ]

diff --git a/libraries/display_tbl.lib.php3 b/libraries/display_tbl.lib.php3 index a9d82d85a..d8b378f69 100644 --- a/libraries/display_tbl.lib.php3 +++ b/libraries/display_tbl.lib.php3 @@ -530,7 +530,7 @@ if (!defined('PMA_DISPLAY_TBL_LIB_INCLUDED')) { } if ($is_display['edit_lnk'] != 'nn') $span++; if ($is_display['del_lnk'] != 'nn') $span++; - + ?> @@ -576,7 +576,7 @@ if (!defined('PMA_DISPLAY_TBL_LIB_INCLUDED')) { } } - + if ($disp_direction == 'horizontal' || $disp_direction == 'horizontalflipped') { ?> @@ -594,7 +594,11 @@ if (!defined('PMA_DISPLAY_TBL_LIB_INCLUDED')) { if ($is_display['del_lnk'] == 'dr') { echo '
' . "\n"; - echo PMA_generate_common_hidden_inputs($db, $table, 1); + echo PMA_generate_common_hidden_inputs($db, $table, 1); + echo '' . "\n"; + echo '' . "\n"; + echo '' . "\n"; + echo '' . "\n"; } // 1. Displays the full/partial text button (part 1)... @@ -604,7 +608,7 @@ if (!defined('PMA_DISPLAY_TBL_LIB_INCLUDED')) { : ''; } else { $rowspan = ($is_display['edit_lnk'] != 'nn' && $is_display['del_lnk'] != 'nn') - ? ' rowspan="2"' + ? ' rowspan="3"' : ''; } $text_url = 'sql.php3?' @@ -712,7 +716,7 @@ if (!defined('PMA_DISPLAY_TBL_LIB_INCLUDED')) { $highlight_columns = array(); if (isset($analyzed_sql) && isset($analyzed_sql[0]) && isset($analyzed_sql[0]['where_clause_identifiers'])) { - + $wi = 0; @reset($analyzed_sql[0]['where_clause_identifiers']); while(list($wci_nr, $wci) = each($analyzed_sql[0]['where_clause_identifiers'])) { @@ -736,7 +740,7 @@ if (!defined('PMA_DISPLAY_TBL_LIB_INCLUDED')) { $comments_table_wrap_pre = ''; $comments_table_wrap_post = ''; } - + // 2.1 Results can be sorted if ($is_display['sort_lnk'] == '1') { @@ -949,10 +953,11 @@ if (!defined('PMA_DISPLAY_TBL_LIB_INCLUDED')) { ' - . PMA_generate_common_hidden_inputs($row['dbase'], '') - . '' - . '' - . '' - . '
'; - } else { + $bookmark_go = ''; + + if ($GLOBALS['cfg']['PropertiesIconic'] == FALSE) { + $bookmark_go .= $GLOBALS['strExecuteBookmarked']; + } else { + $bookmark_go .= $iconic_spacer . '' . $GLOBALS['strExecuteBookmarked'] . ''; + if ($propicon == 'both') { + $bookmark_go .= ' ' . $GLOBALS['strExecuteBookmarked'] . ''; + } + } + + $bookmark_go .= ''; + } else { $bookmark_go = ''; } @@ -1153,7 +1169,7 @@ if (!defined('PMA_DISPLAY_TBL_LIB_INCLUDED')) { $del_query = urlencode('DELETE FROM ' . PMA_backquote($table) . ' WHERE') . $uva_condition . ((PMA_MYSQL_INT_VERSION >= 32207) ? urlencode(' LIMIT 1') : ''); $del_url = 'sql.php3' . '?' . $url_query - . '&sql_query=' . $del_query + . '&sql_query=' . $del_query . '&zero_rows=' . urlencode(htmlspecialchars($GLOBALS['strDeleted'])) . '&goto=' . urlencode($lnk_goto); $js_conf = 'DELETE FROM ' . PMA_jsFormat($table) @@ -1202,7 +1218,7 @@ if (!defined('PMA_DISPLAY_TBL_LIB_INCLUDED')) { // depend on whether the "is_null" php4 function is // available or not $pointer = (function_exists('is_null') ? $i : $meta->name); - + // garvin: See if this column should get highlight because it's used in the // where-query. if (isset($highlight_columns) && (isset($highlight_columns[$meta->name]) || isset($highlight_columns[PMA_backquote($meta->name)]))) { @@ -1224,9 +1240,9 @@ if (!defined('PMA_DISPLAY_TBL_LIB_INCLUDED')) { if (file_exists('./libraries/transformations/' . $include_file)) { $transformfunction_name = str_replace('.inc.php3', '', $GLOBALS['mime_map'][$meta->name]['transformation']); - + include('./libraries/transformations/' . $include_file); - + if (defined('PMA_TRANSFORMATION_' . strtoupper($transformfunction_name)) && function_exists('PMA_transformation_' . $transformfunction_name)) { $transform_function = 'PMA_transformation_' . $transformfunction_name; $transform_options = PMA_transformation_getOptions((isset($GLOBALS['mime_map'][$meta->name]['transformation_options']) ? $GLOBALS['mime_map'][$meta->name]['transformation_options'] : '')); @@ -1245,7 +1261,7 @@ if (!defined('PMA_DISPLAY_TBL_LIB_INCLUDED')) { // n u m e r i c if ($meta->numeric == 1) { - + // lem9: if two fields have the same name (this is possible // with self-join queries, for example), using $meta->name @@ -1380,7 +1396,7 @@ if (!defined('PMA_DISPLAY_TBL_LIB_INCLUDED')) { // garvin: transform functions may enable nowrapping: $function_nowrap = $transform_function . '_nowrap'; $bool_nowrap = (($default_function != $transform_function && function_exists($function_nowrap)) ? $function_nowrap($transform_options) : false); - + // loic1: do not wrap if date field type $nowrap = ((eregi('DATE|TIME', $meta->type) || $bool_nowrap) ? ' nowrap="nowrap"' : ''); $vertical_display['data'][$row_no][$i] = ' '; @@ -1458,8 +1474,16 @@ if (!defined('PMA_DISPLAY_TBL_LIB_INCLUDED')) { // 4. Gather links of del_urls and edit_urls in an array for later // output if (!isset($vertical_display['edit'][$row_no])) { - $vertical_display['edit'][$row_no] = ''; - $vertical_display['delete'][$row_no] = ''; + $vertical_display['edit'][$row_no] = ''; + $vertical_display['delete'][$row_no] = ''; + $vertical_display['row_delete'][$row_no] = ''; + } + + + if (!empty($del_url)) { + $vertical_display['row_delete'][$row_no] .= ' ' . "\n" + . ' ' . "\n" + . ' ' . "\n"; } if (isset($edit_url)) { @@ -1506,10 +1530,29 @@ if (!defined('PMA_DISPLAY_TBL_LIB_INCLUDED')) { reset($vertical_display); + // Displays "multi row delete" link at top if required + if ($GLOBALS['cfg']['ModifyDeleteAtLeft'] && is_array($vertical_display['row_delete'])) { + echo '' . "\n"; + echo $vertical_display['textbtn']; + reset($vertical_display['row_delete']); + $foo_counter = 0; + while (list($key, $val) = each($vertical_display['row_delete'])) { + if (($foo_counter != 0) && ($repeat_cells != 0) && !($foo_counter % $repeat_cells)) { + echo ' ' . "\n"; + } + + echo $val; + $foo_counter++; + } // end while + echo '' . "\n"; + } // end if + // Displays "edit" link at top if required if ($GLOBALS['cfg']['ModifyDeleteAtLeft'] && is_array($vertical_display['edit'])) { echo '' . "\n"; - echo $vertical_display['textbtn']; + if (!is_array($vertical_display['row_delete'])) { + echo $vertical_display['textbtn']; + } reset($vertical_display['edit']); $foo_counter = 0; while (list($key, $val) = each($vertical_display['edit'])) { @@ -1526,7 +1569,7 @@ if (!defined('PMA_DISPLAY_TBL_LIB_INCLUDED')) { // Displays "delete" link at top if required if ($GLOBALS['cfg']['ModifyDeleteAtLeft'] && is_array($vertical_display['delete'])) { echo '' . "\n"; - if (!is_array($vertical_display['edit'])) { + if (!is_array($vertical_display['edit']) && !is_array($vertical_display['row_delete'])) { echo $vertical_display['textbtn']; } reset($vertical_display['delete']); @@ -1581,10 +1624,29 @@ if (!defined('PMA_DISPLAY_TBL_LIB_INCLUDED')) { echo '' . "\n"; } // end while + // Displays "multi row delete" link at bottom if required + if ($GLOBALS['cfg']['ModifyDeleteAtRight'] && is_array($vertical_display['row_delete'])) { + echo '' . "\n"; + echo $vertical_display['textbtn']; + reset($vertical_display['row_delete']); + $foo_counter = 0; + while (list($key, $val) = each($vertical_display['row_delete'])) { + if (($foo_counter != 0) && ($repeat_cells != 0) && !($foo_counter % $repeat_cells)) { + echo ' ' . "\n"; + } + + echo $val; + $foo_counter++; + } // end while + echo '' . "\n"; + } // end if + // Displays "edit" link at bottom if required if ($GLOBALS['cfg']['ModifyDeleteAtRight'] && is_array($vertical_display['edit'])) { echo '' . "\n"; - echo $vertical_display['textbtn']; + if (!is_array($vertical_display['row_delete'])) { + echo $vertical_display['textbtn']; + } reset($vertical_display['edit']); $foo_counter = 0; while (list($key, $val) = each($vertical_display['edit'])) { @@ -1601,7 +1663,7 @@ if (!defined('PMA_DISPLAY_TBL_LIB_INCLUDED')) { // Displays "delete" link at bottom if required if ($GLOBALS['cfg']['ModifyDeleteAtRight'] && is_array($vertical_display['delete'])) { echo '' . "\n"; - if (!is_array($vertical_display['edit'])) { + if (!is_array($vertical_display['edit']) && !is_array($vertical_display['row_delete'])) { echo $vertical_display['textbtn']; } reset($vertical_display['delete']); @@ -1799,7 +1861,7 @@ if (!defined('PMA_DISPLAY_TBL_LIB_INCLUDED')) { . '' . $GLOBALS['strDelete'] . '' . (($propicon == 'both') ? ' ' . $GLOBALS['strDelete'] : '') . "\n" . ''; } else { - echo ' ' . (($propicon == 'both') ? ' ' . $GLOBALS['strDelete'] : ''); + echo ' ' . (($propicon == 'both') ? ' ' . $GLOBALS['strDelete'] : ''); } echo "\n"; } else { @@ -1826,7 +1888,7 @@ if (!defined('PMA_DISPLAY_TBL_LIB_INCLUDED')) { $buffer = htmlspecialchars($buffer); $buffer = str_replace("\011", '    ', str_replace(' ', '  ', $buffer)); $buffer = ereg_replace("((\015\012)|(\015)|(\012))", '
', $buffer); - + return $buffer; } } // $__PMA_DISPLAY_TBL_LIB__ diff --git a/tbl_row_delete.php3 b/tbl_row_delete.php3 index 3681ec11a..6e74c85fd 100755 --- a/tbl_row_delete.php3 +++ b/tbl_row_delete.php3 @@ -1,7 +1,6 @@