diff --git a/libraries/bookmark.lib.php b/libraries/bookmark.lib.php
index 69753cd22..6e5b6485f 100644
--- a/libraries/bookmark.lib.php
+++ b/libraries/bookmark.lib.php
@@ -132,7 +132,7 @@ function PMA_addBookmarks($fields, $cfgBookmark, $all_users = false)
global $controllink;
$query = 'INSERT INTO ' . PMA_backquote($cfgBookmark['db']) . '.' . PMA_backquote($cfgBookmark['table'])
- . ' (id, dbase, user, query, label) VALUES (NULL, \'' . PMA_sqlAddslashes($fields['dbase']) . '\', \'' . ($all_users ? '' : PMA_sqlAddslashes($fields['user'])) . '\', \'' . PMA_sqlAddslashes(urldecode($fields['query'])) . '\', \'' . PMA_sqlAddslashes($fields['label']) . '\')';
+ . ' (id, dbase, user, query, label) VALUES (NULL, \'' . PMA_sqlAddslashes($fields['dbase']) . '\', \'' . ($all_users ? '' : PMA_sqlAddslashes($fields['user'])) . '\', \'' . PMA_sqlAddslashes($fields['query']) . '\', \'' . PMA_sqlAddslashes($fields['label']) . '\')';
$result = PMA_DBI_query($query, $controllink);
return TRUE;
diff --git a/libraries/mult_submits.inc.php b/libraries/mult_submits.inc.php
index 93dcda891..5180fda05 100644
--- a/libraries/mult_submits.inc.php
+++ b/libraries/mult_submits.inc.php
@@ -146,7 +146,7 @@ if (!empty($submit_mult) && !empty($what)) {
foreach ($selected AS $idx => $sval) {
switch ($what) {
case 'row_delete':
- $full_query .= htmlspecialchars(urldecode($sval))
+ $full_query .= htmlspecialchars($sval)
. ';
';
break;
case 'drop_db':
@@ -157,7 +157,7 @@ if (!empty($submit_mult) && !empty($what)) {
break;
case 'drop_tbl':
- $current = urldecode($sval);
+ $current = $sval;
if (!empty($views) && in_array($current, $views)) {
$full_query_views .= (empty($full_query_views) ? 'DROP VIEW ' : ', ')
. PMA_backquote(htmlspecialchars($current));
@@ -169,7 +169,7 @@ if (!empty($submit_mult) && !empty($what)) {
case 'empty_tbl':
$full_query .= 'TRUNCATE ';
- $full_query .= PMA_backquote(htmlspecialchars(urldecode($sval)))
+ $full_query .= PMA_backquote(htmlspecialchars($sval))
. ';
';
break;
@@ -180,11 +180,11 @@ if (!empty($submit_mult) && !empty($what)) {
. '
DROP PRIMARY KEY,'
. '
ADD PRIMARY KEY('
. '
'
- . PMA_backquote(htmlspecialchars(urldecode($sval)))
+ . PMA_backquote(htmlspecialchars($sval))
. ',';
} else {
$full_query .= '
'
- . PMA_backquote(htmlspecialchars(urldecode($sval)))
+ . PMA_backquote(htmlspecialchars($sval))
. ',';
}
if ($i == $selected_cnt-1) {
@@ -198,7 +198,7 @@ if (!empty($submit_mult) && !empty($what)) {
. PMA_backquote(htmlspecialchars($table));
}
$full_query .= '
DROP '
- . PMA_backquote(htmlspecialchars(urldecode($sval)))
+ . PMA_backquote(htmlspecialchars($sval))
. ',';
if ($i == $selected_cnt - 1) {
$full_query = preg_replace('@,$@', ';
', $full_query);
@@ -294,7 +294,7 @@ elseif ($mult_btn == $strYes) {
for ($i = 0; $i < $selected_cnt; $i++) {
switch ($query_type) {
case 'row_delete':
- $a_query = urldecode($selected[$i]);
+ $a_query = $selected[$i];
$run_parts = TRUE;
break;
@@ -309,7 +309,7 @@ elseif ($mult_btn == $strYes) {
case 'drop_tbl':
PMA_relationsCleanupTable($db, $selected[$i]);
- $current = urldecode($selected[$i]);
+ $current = $selected[$i];
if (!empty($views) && in_array($current, $views)) {
$sql_query_views .= (empty($sql_query_views) ? 'DROP VIEW ' : ', ')
. PMA_backquote($current);
@@ -322,62 +322,62 @@ elseif ($mult_btn == $strYes) {
case 'check_tbl':
$sql_query .= (empty($sql_query) ? 'CHECK TABLE ' : ', ')
- . PMA_backquote(urldecode($selected[$i]));
+ . PMA_backquote($selected[$i]);
$use_sql = TRUE;
break;
case 'optimize_tbl':
$sql_query .= (empty($sql_query) ? 'OPTIMIZE TABLE ' : ', ')
- . PMA_backquote(urldecode($selected[$i]));
+ . PMA_backquote($selected[$i]);
$use_sql = TRUE;
break;
case 'analyze_tbl':
$sql_query .= (empty($sql_query) ? 'ANALYZE TABLE ' : ', ')
- . PMA_backquote(urldecode($selected[$i]));
+ . PMA_backquote($selected[$i]);
$use_sql = TRUE;
break;
case 'repair_tbl':
$sql_query .= (empty($sql_query) ? 'REPAIR TABLE ' : ', ')
- . PMA_backquote(urldecode($selected[$i]));
+ . PMA_backquote($selected[$i]);
$use_sql = TRUE;
break;
case 'empty_tbl':
$a_query = 'TRUNCATE ';
- $a_query .= PMA_backquote(htmlspecialchars(urldecode($selected[$i])));
+ $a_query .= PMA_backquote(htmlspecialchars($selected[$i]));
$run_parts = TRUE;
break;
case 'drop_fld':
PMA_relationsCleanupColumn($db, $table, $selected[$i]);
$sql_query .= (empty($sql_query) ? 'ALTER TABLE ' . PMA_backquote($table) : ',')
- . ' DROP ' . PMA_backquote(urldecode($selected[$i]))
+ . ' DROP ' . PMA_backquote($selected[$i])
. (($i == $selected_cnt-1) ? ';' : '');
break;
case 'primary_fld':
$sql_query .= (empty($sql_query) ? 'ALTER TABLE ' . PMA_backquote($table) . (empty($primary) ? '' : ' DROP PRIMARY KEY,') . ' ADD PRIMARY KEY( ' : ', ')
- . PMA_backquote(urldecode($selected[$i]))
+ . PMA_backquote($selected[$i])
. (($i == $selected_cnt-1) ? ');' : '');
break;
case 'index_fld':
$sql_query .= (empty($sql_query) ? 'ALTER TABLE ' . PMA_backquote($table) . ' ADD INDEX( ' : ', ')
- . PMA_backquote(urldecode($selected[$i]))
+ . PMA_backquote($selected[$i])
. (($i == $selected_cnt-1) ? ');' : '');
break;
case 'unique_fld':
$sql_query .= (empty($sql_query) ? 'ALTER TABLE ' . PMA_backquote($table) . ' ADD UNIQUE( ' : ', ')
- . PMA_backquote(urldecode($selected[$i]))
+ . PMA_backquote($selected[$i])
. (($i == $selected_cnt-1) ? ');' : '');
break;
case 'fulltext_fld':
$sql_query .= (empty($sql_query) ? 'ALTER TABLE ' . PMA_backquote($table) . ' ADD FULLTEXT( ' : ', ')
- . PMA_backquote(urldecode($selected[$i]))
+ . PMA_backquote($selected[$i])
. (($i == $selected_cnt-1) ? ');' : '');
break;
} // end switch
diff --git a/libraries/relation_cleanup.lib.php b/libraries/relation_cleanup.lib.php
index 47b7198b8..89a7584cd 100644
--- a/libraries/relation_cleanup.lib.php
+++ b/libraries/relation_cleanup.lib.php
@@ -18,7 +18,7 @@ function PMA_relationsCleanupColumn($db, $table, $column) {
$remove_query = 'DELETE FROM ' . PMA_backquote($GLOBALS['cfgRelation']['db']) . '.' . PMA_backquote($cfgRelation['column_info'])
. ' WHERE db_name = \'' . PMA_sqlAddslashes($db) . '\''
. ' AND table_name = \'' . PMA_sqlAddslashes($table) . '\''
- . ' AND column_name = \'' . PMA_sqlAddslashes(urldecode($column)) . '\'';
+ . ' AND column_name = \'' . PMA_sqlAddslashes($column) . '\'';
$rmv_rs = PMA_query_as_cu($remove_query);
unset($remove_query);
}
@@ -27,7 +27,7 @@ function PMA_relationsCleanupColumn($db, $table, $column) {
$remove_query = 'DELETE FROM ' . PMA_backquote($GLOBALS['cfgRelation']['db']) . '.' . PMA_backquote($cfgRelation['table_info'])
. ' WHERE db_name = \'' . PMA_sqlAddslashes($db) . '\''
. ' AND table_name = \'' . PMA_sqlAddslashes($table) . '\''
- . ' AND display_field = \'' . PMA_sqlAddslashes(urldecode($column)) . '\'';
+ . ' AND display_field = \'' . PMA_sqlAddslashes($column) . '\'';
$rmv_rs = PMA_query_as_cu($remove_query);
unset($remove_query);
}
@@ -36,14 +36,14 @@ function PMA_relationsCleanupColumn($db, $table, $column) {
$remove_query = 'DELETE FROM ' . PMA_backquote($GLOBALS['cfgRelation']['db']) . '.' . PMA_backquote($cfgRelation['relation'])
. ' WHERE master_db = \'' . PMA_sqlAddslashes($db) . '\''
. ' AND master_table = \'' . PMA_sqlAddslashes($table) . '\''
- . ' AND master_field = \'' . PMA_sqlAddslashes(urldecode($column)) . '\'';
+ . ' AND master_field = \'' . PMA_sqlAddslashes($column) . '\'';
$rmv_rs = PMA_query_as_cu($remove_query);
unset($remove_query);
$remove_query = 'DELETE FROM ' . PMA_backquote($GLOBALS['cfgRelation']['db']) . '.' . PMA_backquote($cfgRelation['relation'])
. ' WHERE foreign_db = \'' . PMA_sqlAddslashes($db) . '\''
. ' AND foreign_table = \'' . PMA_sqlAddslashes($table) . '\''
- . ' AND foreign_field = \'' . PMA_sqlAddslashes(urldecode($column)) . '\'';
+ . ' AND foreign_field = \'' . PMA_sqlAddslashes($column) . '\'';
$rmv_rs = PMA_query_as_cu($remove_query);
unset($remove_query);
}
diff --git a/tbl_printview.php b/tbl_printview.php
index 4ebda1f65..02ff2b82e 100644
--- a/tbl_printview.php
+++ b/tbl_printview.php
@@ -69,7 +69,7 @@ if ($multi_tables) {
$tbl_list = '';
foreach ($the_tables as $key => $table) {
$tbl_list .= (empty($tbl_list) ? '' : ', ')
- . PMA_backquote(urldecode($table));
+ . PMA_backquote($table);
}
echo ''. $strShowTables . ': ' . $tbl_list . '' . "\n";
echo '