Export only SELECT queries, do not show multi row actions when no checkboxes shown.
This commit is contained in:
@@ -15,6 +15,8 @@ $Source$
|
|||||||
css/phpmyadmin.css.php: Get rid of wrap="virtual" to achieve more XHTML
|
css/phpmyadmin.css.php: Get rid of wrap="virtual" to achieve more XHTML
|
||||||
validity.
|
validity.
|
||||||
* libraries/common.lib.php, lang/*: Add Refresh link (RFE #942110).
|
* libraries/common.lib.php, lang/*: Add Refresh link (RFE #942110).
|
||||||
|
* sql.php, libraries/display_tbl.lib.php: Export only SELECT queries, do
|
||||||
|
not show multi row actions when no checkboxes shown.
|
||||||
|
|
||||||
2004-05-03 Garvin Hicking <pma@supergarv.de>
|
2004-05-03 Garvin Hicking <pma@supergarv.de>
|
||||||
* left.php: Bug #946501 - Nested table now also work with aliased
|
* left.php: Bug #946501 - Nested table now also work with aliased
|
||||||
|
@@ -1797,7 +1797,7 @@ function PMA_displayTable(&$dt_result, &$the_disp_mode, $analyzed_sql)
|
|||||||
|
|
||||||
// 4. ----- Displays the link for multi-fields delete
|
// 4. ----- Displays the link for multi-fields delete
|
||||||
|
|
||||||
if ($is_display['del_lnk'] == 'dr' || $is_display['del_lnk'] == 'kp') {
|
if ($is_display['del_lnk'] == 'dr' && $is_display['del_lnk'] != 'kp') {
|
||||||
|
|
||||||
$delete_text = $is_display['del_lnk'] == 'dr' ? $GLOBALS['strDelete'] : $GLOBALS['strKill'];
|
$delete_text = $is_display['del_lnk'] == 'dr' ? $GLOBALS['strDelete'] : $GLOBALS['strKill'];
|
||||||
$propicon = (string)$GLOBALS['cfg']['PropertiesIconic'];
|
$propicon = (string)$GLOBALS['cfg']['PropertiesIconic'];
|
||||||
@@ -1816,21 +1816,26 @@ function PMA_displayTable(&$dt_result, &$the_disp_mode, $analyzed_sql)
|
|||||||
echo ' <button class="mult_submit" type="submit" name="submit_mult" value="row_delete" title="' . $delete_text . '">' . "\n"
|
echo ' <button class="mult_submit" type="submit" name="submit_mult" value="row_delete" title="' . $delete_text . '">' . "\n"
|
||||||
. '<img src="./images/button_drop.png" title="' . $delete_text . '" alt="' . $delete_text . '" width="12" height="13" />' . (($propicon == 'both') ? ' ' . $delete_text : '') . "\n"
|
. '<img src="./images/button_drop.png" title="' . $delete_text . '" alt="' . $delete_text . '" width="12" height="13" />' . (($propicon == 'both') ? ' ' . $delete_text : '') . "\n"
|
||||||
. '</button>';
|
. '</button>';
|
||||||
|
if ($analyzed_sql[0]['querytype'] == 'SELECT') {
|
||||||
echo ' <button class="mult_submit" type="submit" name="submit_mult" value="row_export" title="' . $GLOBALS['strExport'] . '">' . "\n"
|
echo ' <button class="mult_submit" type="submit" name="submit_mult" value="row_export" title="' . $GLOBALS['strExport'] . '">' . "\n"
|
||||||
. '<img src="./images/button_export.png" title="' . $GLOBALS['strExport'] . '" alt="' . $GLOBALS['strExport'] . '" width="12" height="13" />' . (($propicon == 'both') ? ' ' . $GLOBALS['strExport'] : '') . "\n"
|
. '<img src="./images/button_export.png" title="' . $GLOBALS['strExport'] . '" alt="' . $GLOBALS['strExport'] . '" width="12" height="13" />' . (($propicon == 'both') ? ' ' . $GLOBALS['strExport'] : '') . "\n"
|
||||||
. '</button>';
|
. '</button>';
|
||||||
|
}
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
echo ' <input type="image" name="submit_mult_edit" value="row_edit" title="' . $GLOBALS['strEdit'] . '" src="./images/button_edit.png" />' . (($propicon == 'both') ? ' ' . $GLOBALS['strEdit'] : '');
|
echo ' <input type="image" name="submit_mult_edit" value="row_edit" title="' . $GLOBALS['strEdit'] . '" src="./images/button_edit.png" />' . (($propicon == 'both') ? ' ' . $GLOBALS['strEdit'] : '');
|
||||||
echo ' <input type="image" name="submit_mult" value="row_delete" title="' . $delete_text . '" src="./images/button_drop.png" />' . (($propicon == 'both') ? ' ' . $delete_text : '');
|
echo ' <input type="image" name="submit_mult" value="row_delete" title="' . $delete_text . '" src="./images/button_drop.png" />' . (($propicon == 'both') ? ' ' . $delete_text : '');
|
||||||
echo ' <input type="image" name="submit_mult_export" value="row_export" title="' . $GLOBALS['strExport'] . '" src="./images/button_export.png" />' . (($propicon == 'both') ? ' ' . $GLOBALS['strExport'] : '');
|
if ($analyzed_sql[0]['querytype'] == 'SELECT') {
|
||||||
|
echo ' <input type="image" name="submit_mult_export" value="row_export" title="' . $GLOBALS['strExport'] . '" src="./images/button_export.png" />' . (($propicon == 'both') ? ' ' . $GLOBALS['strExport'] : '');
|
||||||
|
}
|
||||||
}
|
}
|
||||||
echo "\n";
|
echo "\n";
|
||||||
} else {
|
} else {
|
||||||
echo ' <input type="submit" name="submit_mult" value="' . htmlspecialchars($GLOBALS['strEdit']) . '" title="' . $GLOBALS['strEdit'] . '" />' . "\n";
|
echo ' <input type="submit" name="submit_mult" value="' . htmlspecialchars($GLOBALS['strEdit']) . '" title="' . $GLOBALS['strEdit'] . '" />' . "\n";
|
||||||
echo ' <input type="submit" name="submit_mult" value="' . htmlspecialchars($delete_text) . '" title="' . $delete_text . '" />' . "\n";
|
echo ' <input type="submit" name="submit_mult" value="' . htmlspecialchars($delete_text) . '" title="' . $delete_text . '" />' . "\n";
|
||||||
echo ' <input type="submit" name="submit_mult" value="' . htmlspecialchars($GLOBALS['strExport']) . '" title="' . $GLOBALS['strExport'] . '" />' . "\n";
|
if ($analyzed_sql[0]['querytype'] == 'SELECT') {
|
||||||
|
echo ' <input type="submit" name="submit_mult" value="' . htmlspecialchars($GLOBALS['strExport']) . '" title="' . $GLOBALS['strExport'] . '" />' . "\n";
|
||||||
|
}
|
||||||
}
|
}
|
||||||
echo '<input type="hidden" name="sql_query" value="' . $encoded_sql_query . '" />' . "\n";
|
echo '<input type="hidden" name="sql_query" value="' . $encoded_sql_query . '" />' . "\n";
|
||||||
echo '<input type="hidden" name="pos" value="' . $pos . '" />' . "\n";
|
echo '<input type="hidden" name="pos" value="' . $pos . '" />' . "\n";
|
||||||
|
2
sql.php
2
sql.php
@@ -726,7 +726,7 @@ else {
|
|||||||
// (the url_query has extra parameters that won't be used to export)
|
// (the url_query has extra parameters that won't be used to export)
|
||||||
// (the single_table parameter is used in display_export.lib.php
|
// (the single_table parameter is used in display_export.lib.php
|
||||||
// to hide the SQL and the structure export dialogs)
|
// to hide the SQL and the structure export dialogs)
|
||||||
if (!isset($printview)) {
|
if ($analyzed_sql[0]['querytype'] == 'SELECT' && !isset($printview)) {
|
||||||
if (isset($analyzed_sql[0]['table_ref'][0]['table_true_name']) && !isset($analyzed_sql[0]['table_ref'][1]['table_true_name'])) {
|
if (isset($analyzed_sql[0]['table_ref'][0]['table_true_name']) && !isset($analyzed_sql[0]['table_ref'][1]['table_true_name'])) {
|
||||||
$single_table = '&single_table=true';
|
$single_table = '&single_table=true';
|
||||||
} else {
|
} else {
|
||||||
|
Reference in New Issue
Block a user