New URL and hidden input generating stuff.
This commit is contained in:
@@ -5,6 +5,11 @@ phpMyAdmin - Changelog
|
||||
$Id$
|
||||
$Source$
|
||||
|
||||
2003-01-08 Michal Cihar <nijel@users.sourceforge.net>
|
||||
* libraries/url_generation.lib.php3, libraries/common.lib.php3: New URL
|
||||
and hidden input generating stuff.
|
||||
* almost all php3 files: Use new URL and hidden input generation stuff.
|
||||
|
||||
2003-01-08 Alexander M. Turek <rabus@users.sourceforge.net>
|
||||
* lang/english-*.inc.php3: Fixed a typo.
|
||||
|
||||
|
@@ -14,11 +14,7 @@ require('./header.inc.php3');
|
||||
/**
|
||||
* Defines the url to return to in case of error in a sql statement
|
||||
*/
|
||||
$err_url = 'main.php3'
|
||||
. '?lang=' . $lang
|
||||
. '&convcharset=' . $convcharset
|
||||
. '&server=' . $server;
|
||||
|
||||
$err_url = 'main.php3?' . PMA_generate_common_url();
|
||||
|
||||
/**
|
||||
* Ensures the db name is valid
|
||||
|
@@ -21,18 +21,9 @@ require('./libraries/relation.lib.php3');
|
||||
* Defines the url to return to in case of error in a sql statement
|
||||
*/
|
||||
if (isset($table)) {
|
||||
$err_url = 'tbl_properties.php3'
|
||||
. '?lang=' . $lang
|
||||
. '&convcharset=' . $convcharset
|
||||
. '&server=' . $server
|
||||
. '&db=' . urlencode($db)
|
||||
. '&table=' . urlencode($table);
|
||||
$err_url = 'tbl_properties.php3?' . PMA_generate_common_url($db, $table);
|
||||
} else {
|
||||
$err_url = 'db_details.php3'
|
||||
. '?lang=' . $lang
|
||||
. '&convcharset=' . $convcharset
|
||||
. '&server=' . $server
|
||||
. '&db=' . urlencode($db);
|
||||
$err_url = 'db_details.php3?' . PMA_generate_common_url($db);
|
||||
}
|
||||
|
||||
|
||||
|
@@ -57,10 +57,7 @@ $auto_sel = ($cfg['TextareaAutoSelect'])
|
||||
<form method="post" action="read_dump.php3"<?php if ($is_upload) echo ' enctype="multipart/form-data"'; echo "\n"; ?>
|
||||
onsubmit="return checkSqlQuery(this)">
|
||||
<input type="hidden" name="is_js_confirmed" value="0" />
|
||||
<input type="hidden" name="lang" value="<?php echo $lang; ?>" />
|
||||
<input type="hidden" name="convcharset" value="<?php echo $convcharset; ?>" />
|
||||
<input type="hidden" name="server" value="<?php echo $server; ?>" />
|
||||
<input type="hidden" name="db" value="<?php echo htmlspecialchars($db); ?>" />
|
||||
<?php echo PMA_generate_common_hidden_inputs($db); ?>
|
||||
<input type="hidden" name="pos" value="0" />
|
||||
<input type="hidden" name="goto" value="db_details.php3" />
|
||||
<input type="hidden" name="zero_rows" value="<?php echo htmlspecialchars($strSuccess); ?>" />
|
||||
|
@@ -19,15 +19,8 @@ if (!defined('PMA_BOOKMARK_LIB_INCLUDED')) {
|
||||
/**
|
||||
* Defines the urls to return to in case of error in a sql statement
|
||||
*/
|
||||
$err_url_0 = 'main.php3'
|
||||
. '?lang=' . $lang
|
||||
. '&convcharset=' . $convcharset
|
||||
. '&server=' . $server;
|
||||
$err_url = $cfg['DefaultTabDatabase']
|
||||
. '?lang=' . $lang
|
||||
. '&convcharset=' . $convcharset
|
||||
. '&server=' . $server
|
||||
. '&db=' . urlencode($db);
|
||||
$err_url_0 = 'main.php3?' . PMA_generate_common_url();
|
||||
$err_url = $cfg['DefaultTabDatabase'] . '?' . PMA_generate_common_url($db);
|
||||
|
||||
|
||||
/**
|
||||
@@ -40,7 +33,7 @@ if (!isset($is_db) || !$is_db) {
|
||||
$is_db = @PMA_mysql_select_db($db);
|
||||
}
|
||||
if (empty($db) || !$is_db) {
|
||||
header('Location: ' . $cfg['PmaAbsoluteUri'] . 'main.php3?lang=' . $lang . '&convcharset=' . $convcharset . '&server=' . $server . (isset($message) ? '&message=' . urlencode($message) : '') . '&reload=1');
|
||||
header('Location: ' . $cfg['PmaAbsoluteUri'] . 'main.php3?' . PMA_generate_common_url() . (isset($message) ? '&message=' . urlencode($message) : '') . '&reload=1');
|
||||
exit();
|
||||
}
|
||||
} // end if (ensures db exists)
|
||||
@@ -54,7 +47,7 @@ if (!isset($message)) {
|
||||
?>
|
||||
<script type="text/javascript" language="javascript1.2">
|
||||
<!--
|
||||
window.parent.frames['nav'].location.replace('./left.php3?lang=<?php echo $lang; ?> &convcharset=<?php echo $convcharset; ?>&server=<?php echo $server; ?>&db=<?php echo urlencode($db); ?>');
|
||||
window.parent.frames['nav'].location.replace('./left.php3?<?php echo PMA_generate_common_url($db); ?>');
|
||||
//-->
|
||||
</script>
|
||||
<?php
|
||||
@@ -67,9 +60,6 @@ window.parent.frames['nav'].location.replace('./left.php3?lang=<?php echo $lang;
|
||||
/**
|
||||
* Set parameters for links
|
||||
*/
|
||||
$url_query = 'lang=' . $lang
|
||||
. '&convcharset=' . $convcharset
|
||||
. '&server=' . $server
|
||||
. '&db=' . urlencode($db);
|
||||
$url_query = PMA_generate_common_url($db);
|
||||
|
||||
?>
|
||||
|
@@ -68,11 +68,8 @@ echo "\n";
|
||||
|
||||
<?php
|
||||
if ($num_tables > 1) {
|
||||
$checkall_url = 'db_details_export.php3'
|
||||
. '?lang=' . $lang
|
||||
. '&convcharset=' . $convcharset
|
||||
. '&server=' . $server
|
||||
. '&db=' . urlencode($db)
|
||||
$checkall_url = 'db_details_export.php3?'
|
||||
. PMA_generate_common_url($db)
|
||||
. '&goto=db_details_export.php3';
|
||||
?>
|
||||
<br />
|
||||
@@ -191,9 +188,7 @@ if (function_exists('PMA_set_enc_form')) {
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<input type="hidden" name="server" value="<?php echo $server; ?>" />
|
||||
<input type="hidden" name="lang" value="<?php echo $lang;?>" />
|
||||
<input type="hidden" name="db" value="<?php echo htmlspecialchars($db);?>" />
|
||||
<?php echo PMA_generate_common_hidden_inputs($db); ?>
|
||||
</form>
|
||||
|
||||
<a href="./Documentation.html#faqexport" target="documentation"><?php echo $strDocu; ?></a>
|
||||
|
@@ -123,9 +123,7 @@ if (empty($DOCUMENT_ROOT)) {
|
||||
?>
|
||||
|
||||
<form method="post" action="db_details_importdocsql.php3">
|
||||
<input type="hidden" name="lang" value="<?php echo $lang; ?>" />
|
||||
<input type="hidden" name="server" value="<?php echo $server; ?>" />
|
||||
<input type="hidden" name="db" value="<?php echo htmlspecialchars($db); ?>" />
|
||||
<?php echo PMA_generate_common_hidden_inputs($db); ?>
|
||||
<input type="hidden" name="submit_show" value="true" />
|
||||
<input type="hidden" name="do" value="import" />
|
||||
<b>Please enter absolute path on webserver to docSQL Directory:</b>
|
||||
|
@@ -685,9 +685,7 @@ $w--;
|
||||
<tr align="center" valign="top">
|
||||
<td>
|
||||
<input type="submit" name="modify" value="<?php echo $strUpdateQuery; ?>" />
|
||||
<input type="hidden" name="server" value="<?php echo $server; ?>" />
|
||||
<input type="hidden" name="lang" value="<?php echo $lang; ?>" />
|
||||
<input type="hidden" name="convcharset" value="<?php echo $convcharset; ?>" />
|
||||
<?php echo PMA_generate_common_hidden_inputs(); ?>
|
||||
</td>
|
||||
</tr>
|
||||
<!-- Executes a query -->
|
||||
|
@@ -50,10 +50,7 @@ if ($num_tables == 0) {
|
||||
else if (PMA_MYSQL_INT_VERSION >= 32303) {
|
||||
?>
|
||||
<form method="post" action="db_details_structure.php3" name="tablesForm">
|
||||
<input type="hidden" name="lang" value="<?php echo $lang; ?>" />
|
||||
<input type="hidden" name="convcharset" value="<?php echo $convcharset; ?>" />
|
||||
<input type="hidden" name="server" value="<?php echo $server; ?>" />
|
||||
<input type="hidden" name="db" value="<?php echo htmlspecialchars($db); ?>" />
|
||||
<?php echo PMA_generate_common_hidden_inputs($db); ?>
|
||||
|
||||
<table border="<?php echo $cfg['Border']; ?>">
|
||||
<tr>
|
||||
@@ -270,11 +267,7 @@ else if (PMA_MYSQL_INT_VERSION >= 32303) {
|
||||
|
||||
<?php
|
||||
// Check all tables url
|
||||
$checkall_url = 'db_details_structure.php3'
|
||||
. '?lang=' . $lang
|
||||
. '&convcharset=' . $convcharset
|
||||
. '&server=' . $server
|
||||
. '&db=' . urlencode($db);
|
||||
$checkall_url = 'db_details_structure.php3?' . PMA_generate_common_url($db);
|
||||
echo "\n";
|
||||
?>
|
||||
<tr>
|
||||
@@ -326,10 +319,7 @@ else {
|
||||
echo "\n";
|
||||
?>
|
||||
<form action="db_details_structure.php3">
|
||||
<input type="hidden" name="lang" value="<?php echo $lang; ?>" />
|
||||
<input type="hidden" name="convcharset" value="<?php echo $convcharset; ?>" />
|
||||
<input type="hidden" name="server" value="<?php echo $server; ?>" />
|
||||
<input type="hidden" name="db" value="<?php echo htmlspecialchars($db); ?>" />
|
||||
<?php echo PMA_generate_common_hidden_inputs($db); ?>
|
||||
|
||||
<table border="<?php echo $cfg['Border']; ?>">
|
||||
<tr>
|
||||
@@ -385,11 +375,7 @@ else {
|
||||
echo "\n";
|
||||
|
||||
// Check all tables url
|
||||
$checkall_url = 'db_details_structure.php3'
|
||||
. '?lang=' . $lang
|
||||
. '&convcharset=' . $convcharset
|
||||
. '&server=' . $server
|
||||
. '&db=' . urlencode($db);
|
||||
$checkall_url = 'db_details_structure.php3?' . PMA_generate_common_url($db);
|
||||
?>
|
||||
<tr>
|
||||
<td colspan="9">
|
||||
@@ -448,10 +434,7 @@ if ($num_tables > 0) {
|
||||
<li>
|
||||
<form method="post" action="tbl_create.php3"
|
||||
onsubmit="return (emptyFormElements(this, 'table') && checkFormElementInRange(this, 'num_fields', 1))">
|
||||
<input type="hidden" name="server" value="<?php echo $server; ?>" />
|
||||
<input type="hidden" name="lang" value="<?php echo $lang; ?>" />
|
||||
<input type="hidden" name="convcharset" value="<?php echo $convcharset; ?>" />
|
||||
<input type="hidden" name="db" value="<?php echo htmlspecialchars($db); ?>" />
|
||||
<?php echo PMA_generate_common_hidden_inputs($db); ?>
|
||||
<?php
|
||||
echo ' ' . sprintf($strCreateNewTable, htmlspecialchars($db)) . ' :<br />' . "\n";
|
||||
echo ' ' . $strName . ' : ' . "\n";
|
||||
@@ -496,10 +479,7 @@ if ($cfgRelation['pdfwork'] && $num_tables > 0) {
|
||||
?>
|
||||
<li>
|
||||
<form method="post" action="pdf_schema.php3">
|
||||
<input type="hidden" name="server" value="<?php echo $server; ?>" />
|
||||
<input type="hidden" name="lang" value="<?php echo $lang; ?>" />
|
||||
<input type="hidden" name="convcharset" value="<?php echo $convcharset; ?>" />
|
||||
<input type="hidden" name="db" value="<?php echo htmlspecialchars($db); ?>" />
|
||||
<?php echo PMA_generate_common_hidden_inputs($db); ?>
|
||||
<?php echo $strDisplayPDF; ?> :<br />
|
||||
<?php echo $strPageNumber; ?>
|
||||
<select name="pdf_page_number">
|
||||
|
@@ -13,11 +13,7 @@ require('./header.inc.php3');
|
||||
/**
|
||||
* Defines the url to return to in case of error in a sql statement
|
||||
*/
|
||||
$err_url = 'db_details.php3'
|
||||
. '?lang=' . $lang
|
||||
. '&convcharset=' . $convcharset
|
||||
. '&server=' . $server
|
||||
. '&db=' . urlencode($db);
|
||||
$err_url = 'db_details.php3?' . PMA_generate_common_url($db);
|
||||
|
||||
|
||||
/**
|
||||
|
@@ -190,12 +190,8 @@ if (isset($submit_search)) {
|
||||
<br />
|
||||
|
||||
<?php
|
||||
$url_sql_query = 'lang=' . $lang
|
||||
. '&convcharset=' . $convcharset
|
||||
. '&server=' . $server
|
||||
$url_sql_query = PMA_generate_common_url($db)
|
||||
. '&goto=db_details.php3'
|
||||
. '&db=' . urlencode($db)
|
||||
// . '&table=' . urlencode($table)
|
||||
. '&pos=0'
|
||||
. '&is_js_confirmed=0';
|
||||
|
||||
@@ -307,10 +303,7 @@ if (empty($search_option)) {
|
||||
|
||||
<a name="db_search"></a>
|
||||
<form method="post" action="db_search.php3" name="db_search">
|
||||
<input type="hidden" name="lang" value="<?php echo $lang; ?>" />
|
||||
<input type="hidden" name="convcharset" value="<?php echo $convcharset; ?>" />
|
||||
<input type="hidden" name="server" value="<?php echo $server; ?>" />
|
||||
<input type="hidden" name="db" value="<?php echo $db; ?>" />
|
||||
<?php echo PMA_generate_common_hidden_inputs($db); ?>
|
||||
|
||||
<table>
|
||||
<tr>
|
||||
|
@@ -26,10 +26,7 @@ if (!@PMA_mysql_query('USE mysql', $userlink)) {
|
||||
*/
|
||||
if ((!empty($submit_mult) && isset($selected_db))
|
||||
|| isset($mult_btn)) {
|
||||
$err_url = 'db_stats.php3'
|
||||
. '?lang=' . $lang
|
||||
. '&convcharset=' . $convcharset
|
||||
. '&server=' . $server;
|
||||
$err_url = 'db_stats.php3?' . PMA_generate_common_url();
|
||||
$action = 'db_stats.php3';
|
||||
$show_query = '1';
|
||||
include('./mult_submits.inc.php3');
|
||||
@@ -83,7 +80,7 @@ function PMA_dbCmp($a, $b)
|
||||
if ($server > 0) {
|
||||
// Get the valid databases list
|
||||
$num_dbs = count($dblist);
|
||||
$dbs = @mysql_list_dbs() or PMA_mysqlDie('', 'mysql_list_dbs()', '', 'main.php3?lang' . $lang . '&server=' . $server);
|
||||
$dbs = @mysql_list_dbs() or PMA_mysqlDie('', 'mysql_list_dbs()', '', 'main.php3?' . PMA_generate_common_url());
|
||||
if ($dbs) {
|
||||
while ($a_db = PMA_mysql_fetch_object($dbs)) {
|
||||
if (!$num_dbs) {
|
||||
@@ -144,7 +141,7 @@ if ($server > 0) {
|
||||
*/
|
||||
if ($num_dbs > 0) {
|
||||
// Defines the urls used to sort the table
|
||||
$common_url = 'db_stats.php3?lang=' . $lang . '&convcharset=' . $convcharset . '&server=' . $server;
|
||||
$common_url = 'db_stats.php3?' . PMA_generate_common_url();
|
||||
if (empty($sort_by)) {
|
||||
$sort_by = 'db_name';
|
||||
$sort_order = 'asc';
|
||||
@@ -185,9 +182,7 @@ if ($num_dbs > 0) {
|
||||
}
|
||||
?>
|
||||
<form action="db_stats.php3" name="dbStatsForm">
|
||||
<input type="hidden" name="lang" value="<?php echo $lang; ?>" />
|
||||
<input type="hidden" name="convcharset" value="<?php echo $convcharset; ?>" />
|
||||
<input type="hidden" name="server" value="<?php echo $server; ?>" />
|
||||
<?php echo PMA_generate_common_hidden_inputs(); ?>
|
||||
|
||||
<table align="center" border="<?php echo $cfg['Border']; ?>">
|
||||
<tr>
|
||||
@@ -271,10 +266,8 @@ if ($num_dbs > 0) {
|
||||
reset($dbs_array);
|
||||
|
||||
// Check/unchek all databases url
|
||||
$checkall_url = 'db_stats.php3'
|
||||
. '?lang=' . $lang
|
||||
. '&convcharset=' . $convcharset
|
||||
. '&server=' . $server
|
||||
$checkall_url = 'db_stats.php3?'
|
||||
. PMA_generate_common_url()
|
||||
. (empty($sort_by) ? '' : '&sort_by=' . $sort_by)
|
||||
. (empty($sort_order) ? '' : '&sort_order=' . $sort_order);
|
||||
$do_check = (empty($checkall))
|
||||
@@ -294,7 +287,7 @@ if ($num_dbs > 0) {
|
||||
echo ' <td align="center" bgcolor="'. $bgcolor . '">' . "\n";
|
||||
echo ' <input type="checkbox" name="selected_db[]" value="' . urlencode($db_name) . '"' . $do_check . ' /> ' . "\n";
|
||||
echo ' </td>' . "\n";
|
||||
echo ' <td bgcolor="'. $bgcolor . '"> <a href="index.php3?lang=' . $lang . '&convcharset=' . $convcharset . '&server=' . $server . '&db=' . urlencode($db_name) . '" target="_parent">' . htmlspecialchars($db_name) . '</a> </td>' . "\n";
|
||||
echo ' <td bgcolor="'. $bgcolor . '"> <a href="index.php3?' . PMA_generate_common_url($db_name) . '" target="_parent">' . htmlspecialchars($db_name) . '</a> </td>' . "\n";
|
||||
echo ' <td align="right" bgcolor="'. $bgcolor . '"> ' . $dbs_array[$db_name][0] . ' </td>' . "\n";
|
||||
echo ' <td align="right" bgcolor="'. $bgcolor . '"> ' . $data_size . '<bdo dir="' . $text_dir . '"> </bdo>' . $data_unit . ' </td>' . "\n";
|
||||
echo ' <td align="right" bgcolor="'. $bgcolor . '"> ' . $idx_size . '<bdo dir="' . $text_dir . '"> </bdo>' . $idx_unit . ' </td>' . "\n";
|
||||
|
@@ -249,9 +249,7 @@ if (!defined('PMA_DISPLAY_HEADING')) {
|
||||
define('PMA_DISPLAY_HEADING', 1);
|
||||
}
|
||||
if (PMA_DISPLAY_HEADING) {
|
||||
$header_url_qry = '?lang=' . urlencode($GLOBALS['lang'])
|
||||
. '&convcharset=' . $GLOBALS['convcharset']
|
||||
. '&server=' . $GLOBALS['server'];
|
||||
$header_url_qry = '?' . PMA_generate_common_url();
|
||||
echo '<h1>' . "\n";
|
||||
$server_info = (!empty($cfg['Server']['verbose'])
|
||||
? $cfg['Server']['verbose']
|
||||
|
@@ -38,10 +38,7 @@ if (isset($lightm_db)) {
|
||||
$db = urldecode($lightm_db);
|
||||
unset($lightm_db);
|
||||
}
|
||||
$url_query = 'lang=' . $lang
|
||||
. '&convcharset=' . $convcharset
|
||||
. '&server=' . $server
|
||||
. (empty($db) ? '' : '&db=' . urlencode($db));
|
||||
$url_query = PMA_generate_common_url(isset($db) ? $db : '');
|
||||
|
||||
header('Content-Type: text/html; charset=' . $GLOBALS['charset']);
|
||||
?>
|
||||
|
@@ -102,11 +102,7 @@ if (function_exists('PMA_set_enc_form')) {
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="3" align="center">
|
||||
<input type="hidden" name="lang" value="<?php echo $lang; ?>" />
|
||||
<input type="hidden" name="convcharset" value="<?php echo $convcharset; ?>" />
|
||||
<input type="hidden" name="server" value="<?php echo $server; ?>" />
|
||||
<input type="hidden" name="db" value="<?php echo htmlspecialchars($db); ?>" />
|
||||
<input type="hidden" name="table" value="<?php echo htmlspecialchars($table); ?>" />
|
||||
<?php echo PMA_generate_common_hidden_inputs($db, $table); ?>
|
||||
<input type="hidden" name="zero_rows" value="<?php echo $strTheContent; ?>" />
|
||||
<input type="hidden" name="goto" value="tbl_properties.php3" />
|
||||
<input type="hidden" name="back" value="ldi_table.php3" />
|
||||
|
15
left.php3
15
left.php3
@@ -179,7 +179,7 @@ echo "\n";
|
||||
?>
|
||||
<!-- Link to the welcome page -->
|
||||
<div id="el1Parent" class="parent" style="margin-bottom: 5px">
|
||||
<nobr><a class="item" href="main.php3?lang=<?php echo $lang; ?>&convcharset=<?php echo $convcharset; ?>&server=<?php echo $server; ?>"><span class="heada"><b><?php echo $strHome; ?></b></span></a></nobr>
|
||||
<nobr><a class="item" href="main.php3?<?php echo PMA_generate_common_url(); ?>"><span class="heada"><b><?php echo $strHome; ?></b></span></a></nobr>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -198,9 +198,7 @@ if ($num_dbs > 1) {
|
||||
// Light mode -> beginning of the select combo for databases
|
||||
if ($cfg['LeftFrameLight']) {
|
||||
echo ' <form method="post" action="index.php3" name="left" target="_parent">' . "\n";
|
||||
echo ' <input type="hidden" name="lang" value="' . $lang . '" />' . "\n";
|
||||
echo ' <input type="hidden" name="convcharset" value="' . $convcharset . '" />' . "\n";
|
||||
echo ' <input type="hidden" name="server" value="' . $server . '" />' . "\n";
|
||||
echo PMA_generate_common_hidden_inputs();
|
||||
echo ' <select name="lightm_db" onchange="this.form.submit()">' . "\n";
|
||||
echo ' <option value="">(' . $strDatabases . ') ...</option>' . "\n";
|
||||
$table_list = '';
|
||||
@@ -219,10 +217,7 @@ if ($num_dbs > 1) {
|
||||
}
|
||||
$tables = @PMA_mysql_list_tables($db);
|
||||
$num_tables = ($tables) ? @mysql_numrows($tables) : 0;
|
||||
$common_url_query = 'lang=' . $lang
|
||||
. '&convcharset=' . $convcharset
|
||||
. '&server=' . $server
|
||||
. '&db=' . urlencode($db);
|
||||
$common_url_query = PMA_generate_common_url($db);
|
||||
if ($num_tables) {
|
||||
$num_tables_disp = $num_tables;
|
||||
} else {
|
||||
@@ -386,9 +381,7 @@ else if ($num_dbs == 1) {
|
||||
$db = $dblist[0];
|
||||
$tables = @PMA_mysql_list_tables($db);
|
||||
$num_tables = ($tables) ? @mysql_numrows($tables) : 0;
|
||||
$common_url_query = 'lang=' . $lang
|
||||
. '&server=' . $server
|
||||
. '&db=' . urlencode($db);
|
||||
$common_url_query = PMA_generate_common_url($db);
|
||||
if ($num_tables) {
|
||||
$num_tables_disp = $num_tables;
|
||||
} else {
|
||||
|
@@ -417,10 +417,10 @@ if (uname.value == '') {
|
||||
}
|
||||
} // end if
|
||||
if (!empty($GLOBALS['SERVER_SOFTWARE']) && $GLOBALS['SERVER_SOFTWARE'] == 'Microsoft-IIS/5.0') {
|
||||
header('Refresh: 0; url=' . $cfg['PmaAbsoluteUri'] . 'index.php3?lang=' . $GLOBALS['lang'] . '&server=' . $server);
|
||||
header('Refresh: 0; url=' . $cfg['PmaAbsoluteUri'] . 'index.php3?' . PMA_generate_common_url());
|
||||
}
|
||||
else {
|
||||
header('Location: ' . $cfg['PmaAbsoluteUri'] . 'index.php3?lang=' . $GLOBALS['lang'] . '&server=' . $server);
|
||||
header('Location: ' . $cfg['PmaAbsoluteUri'] . 'index.php3?' . PMA_generate_common_url());
|
||||
}
|
||||
exit();
|
||||
} // end if
|
||||
|
@@ -190,6 +190,11 @@ h1 {font-family: sans-serif; font-size: large; font-weight: bold}
|
||||
$cfg['OBGzip'] = FALSE;
|
||||
}
|
||||
|
||||
/**
|
||||
* Include URL/hidden inputs generating.
|
||||
*/
|
||||
include('./libraries/url_generating.lib.php3');
|
||||
|
||||
|
||||
/**
|
||||
* Loads the mysql extensions if it is not loaded yet
|
||||
@@ -333,7 +338,7 @@ h1 {font-family: sans-serif; font-size: large; font-weight: bold}
|
||||
echo ' ' . $GLOBALS['strSQLQuery'] . ' : ' . "\n";
|
||||
if ($is_modify_link && isset($db)) {
|
||||
echo ' ['
|
||||
. '<a href="db_details.php3?lang=' . $GLOBALS['lang'] . '&convcharset=' . $GLOBALS['convcharset'] . '&server=' . urlencode($GLOBALS['server']) . '&db=' . urlencode($GLOBALS['db']) . '&sql_query=' . urlencode($the_query) . '&show_query=1">' . $GLOBALS['strEdit'] . '</a>'
|
||||
. '<a href="db_details.php3?' . PMA_generate_common_url($GLOBALS['db']) . '&sql_query=' . urlencode($the_query) . '&show_query=1">' . $GLOBALS['strEdit'] . '</a>'
|
||||
. ']' . "\n";
|
||||
} // end if
|
||||
echo '</p>' . "\n"
|
||||
@@ -1061,11 +1066,7 @@ h1 {font-family: sans-serif; font-size: large; font-weight: bold}
|
||||
// Reloads the navigation frame via JavaScript if required
|
||||
if (isset($GLOBALS['reload']) && $GLOBALS['reload']) {
|
||||
echo "\n";
|
||||
$reload_url = './left.php3'
|
||||
. '?lang=' . $GLOBALS['lang']
|
||||
. '&convcharset=' . $GLOBALS['convcharset']
|
||||
. '&server=' . $GLOBALS['server']
|
||||
. ((!empty($GLOBALS['db'])) ? '&db=' . urlencode($GLOBALS['db']) : '');
|
||||
$reload_url = './left.php3?' . PMA_generate_common_url($GLOBALS['db']);
|
||||
?>
|
||||
<script type="text/javascript" language="javascript1.2">
|
||||
<!--
|
||||
@@ -1135,12 +1136,7 @@ if (typeof(document.getElementById) != 'undefined'
|
||||
<?php
|
||||
if ($cfg['ShowSQL'] == TRUE && !empty($GLOBALS['sql_query'])) {
|
||||
// Basic url query part
|
||||
$url_qpart = '?convcharset=' . $GLOBALS['convcharset']
|
||||
. '&lang=' . $GLOBALS['lang']
|
||||
. '&server=' . $GLOBALS['server']
|
||||
. ((!empty($GLOBALS['db'])) ? '&db=' . urlencode($GLOBALS['db']) : '')
|
||||
. ((!empty($GLOBALS['table'])) ? '&table=' . urlencode($GLOBALS['table']) : '');
|
||||
|
||||
$url_qpart = '?' . PMA_generate_common_url($GLOBALS['db'], $GLOBALS['table']);
|
||||
echo "\n";
|
||||
?>
|
||||
<tr>
|
||||
|
@@ -13,7 +13,7 @@ if (!isset($is_db) || !$is_db) {
|
||||
$is_db = @PMA_mysql_select_db($db);
|
||||
}
|
||||
if (empty($db) || !$is_db) {
|
||||
header('Location: ' . $cfg['PmaAbsoluteUri'] . 'main.php3?lang=' . $lang . '&convcharset=' . $convcharset . '&server=' . $server . (isset($message) ? '&message=' . urlencode($message) : '') . '&reload=1');
|
||||
header('Location: ' . $cfg['PmaAbsoluteUri'] . 'main.php3?' . PMA_generate_common_url() . (isset($message) ? '&message=' . urlencode($message) : '') . '&reload=1');
|
||||
exit();
|
||||
}
|
||||
} // end if (ensures db exists)
|
||||
@@ -24,7 +24,7 @@ if (!isset($is_table) || !$is_table) {
|
||||
}
|
||||
if (empty($table)
|
||||
|| !($is_table && @mysql_numrows($is_table))) {
|
||||
header('Location: ' . $cfg['PmaAbsoluteUri'] . 'db_details.php3?lang=' . $lang . '&convcharset=' . $convcharset . '&server=' . $server . '&db=' . urlencode($db) . (isset($message) ? '&message=' . urlencode($message) : '') . '&reload=1');
|
||||
header('Location: ' . $cfg['PmaAbsoluteUri'] . 'db_details.php3?' . PMA_generate_common_url($db) . (isset($message) ? '&message=' . urlencode($message) : '') . '&reload=1');
|
||||
exit();
|
||||
} else if (isset($is_table)) {
|
||||
mysql_free_result($is_table);
|
||||
|
@@ -238,11 +238,7 @@ if (!defined('PMA_DISPLAY_TBL_LIB_INCLUDED')) {
|
||||
?>
|
||||
<td>
|
||||
<form action="sql.php3" method="post">
|
||||
<input type="hidden" name="lang" value="<?php echo $lang; ?>" />
|
||||
<input type="hidden" name="convcharset" value="<?php echo $convcharset; ?>" />
|
||||
<input type="hidden" name="server" value="<?php echo $server; ?>" />
|
||||
<input type="hidden" name="db" value="<?php echo $db; ?>" />
|
||||
<input type="hidden" name="table" value="<?php echo $table; ?>" />
|
||||
<?php echo PMA_generate_common_hidden_inputs($db, $table); ?>
|
||||
<input type="hidden" name="sql_query" value="<?php echo $encoded_query; ?>" />
|
||||
<input type="hidden" name="pos" value="0" />
|
||||
<input type="hidden" name="session_max_rows" value="<?php echo $session_max_rows; ?>" />
|
||||
@@ -255,11 +251,7 @@ if (!defined('PMA_DISPLAY_TBL_LIB_INCLUDED')) {
|
||||
</td>
|
||||
<td>
|
||||
<form action="sql.php3" method="post">
|
||||
<input type="hidden" name="lang" value="<?php echo $lang; ?>" />
|
||||
<input type="hidden" name="convcharset" value="<?php echo $convcharset; ?>" />
|
||||
<input type="hidden" name="server" value="<?php echo $server; ?>" />
|
||||
<input type="hidden" name="db" value="<?php echo $db; ?>" />
|
||||
<input type="hidden" name="table" value="<?php echo $table; ?>" />
|
||||
<?php echo PMA_generate_common_hidden_inputs($db, $table); ?>
|
||||
<input type="hidden" name="sql_query" value="<?php echo $encoded_query; ?>" />
|
||||
<input type="hidden" name="pos" value="<?php echo $pos_prev; ?>" />
|
||||
<input type="hidden" name="session_max_rows" value="<?php echo $session_max_rows; ?>" />
|
||||
@@ -280,11 +272,7 @@ if (!defined('PMA_DISPLAY_TBL_LIB_INCLUDED')) {
|
||||
<td align="center">
|
||||
<form action="sql.php3" method="post"
|
||||
onsubmit="return (checkFormElementInRange(this, 'session_max_rows', 1) && checkFormElementInRange(this, 'pos', 0, <?php echo $unlim_num_rows - 1; ?>))">
|
||||
<input type="hidden" name="lang" value="<?php echo $lang; ?>" />
|
||||
<input type="hidden" name="convcharset" value="<?php echo $convcharset; ?>" />
|
||||
<input type="hidden" name="server" value="<?php echo $server; ?>" />
|
||||
<input type="hidden" name="db" value="<?php echo $db; ?>" />
|
||||
<input type="hidden" name="table" value="<?php echo $table; ?>" />
|
||||
<?php echo PMA_generate_common_hidden_inputs($db, $table); ?>
|
||||
<input type="hidden" name="sql_query" value="<?php echo $encoded_query; ?>" />
|
||||
<input type="hidden" name="goto" value="<?php echo $goto; ?>" />
|
||||
<input type="hidden" name="dontlimitchars" value="<?php echo $dontlimitchars; ?>" />
|
||||
@@ -329,11 +317,7 @@ if (!defined('PMA_DISPLAY_TBL_LIB_INCLUDED')) {
|
||||
?>
|
||||
<td>
|
||||
<form action="sql.php3" method="post">
|
||||
<input type="hidden" name="lang" value="<?php echo $lang; ?>" />
|
||||
<input type="hidden" name="convcharset" value="<?php echo $convcharset; ?>" />
|
||||
<input type="hidden" name="server" value="<?php echo $server; ?>" />
|
||||
<input type="hidden" name="db" value="<?php echo $db; ?>" />
|
||||
<input type="hidden" name="table" value="<?php echo $table; ?>" />
|
||||
<?php echo PMA_generate_common_hidden_inputs($db, $table); ?>
|
||||
<input type="hidden" name="sql_query" value="<?php echo $encoded_query; ?>" />
|
||||
<input type="hidden" name="pos" value="<?php echo $pos_next; ?>" />
|
||||
<input type="hidden" name="session_max_rows" value="<?php echo $session_max_rows; ?>" />
|
||||
@@ -347,11 +331,7 @@ if (!defined('PMA_DISPLAY_TBL_LIB_INCLUDED')) {
|
||||
<td>
|
||||
<form action="sql.php3" method="post"
|
||||
onsubmit="return <?php echo (($pos + $session_max_rows < $unlim_num_rows && $num_rows >= $session_max_rows) ? 'true' : 'false'); ?>">
|
||||
<input type="hidden" name="lang" value="<?php echo $lang; ?>" />
|
||||
<input type="hidden" name="convcharset" value="<?php echo $convcharset; ?>" />
|
||||
<input type="hidden" name="server" value="<?php echo $server; ?>" />
|
||||
<input type="hidden" name="db" value="<?php echo $db; ?>" />
|
||||
<input type="hidden" name="table" value="<?php echo $table; ?>" />
|
||||
<?php echo PMA_generate_common_hidden_inputs($db, $table); ?>
|
||||
<input type="hidden" name="sql_query" value="<?php echo $encoded_query; ?>" />
|
||||
<input type="hidden" name="pos" value="<?php echo $unlim_num_rows - $session_max_rows; ?>" />
|
||||
<input type="hidden" name="session_max_rows" value="<?php echo $session_max_rows; ?>" />
|
||||
@@ -374,11 +354,7 @@ if (!defined('PMA_DISPLAY_TBL_LIB_INCLUDED')) {
|
||||
</td>
|
||||
<td>
|
||||
<form action="sql.php3" method="post">
|
||||
<input type="hidden" name="lang" value="<?php echo $lang; ?>" />
|
||||
<input type="hidden" name="convcharset" value="<?php echo $convcharset; ?>" />
|
||||
<input type="hidden" name="server" value="<?php echo $server; ?>" />
|
||||
<input type="hidden" name="db" value="<?php echo $db; ?>" />
|
||||
<input type="hidden" name="table" value="<?php echo $table; ?>" />
|
||||
<?php echo PMA_generate_common_hidden_inputs($db, $table); ?>
|
||||
<input type="hidden" name="sql_query" value="<?php echo $encoded_query; ?>" />
|
||||
<input type="hidden" name="pos" value="0" />
|
||||
<input type="hidden" name="session_max_rows" value="all" />
|
||||
@@ -460,12 +436,8 @@ if (!defined('PMA_DISPLAY_TBL_LIB_INCLUDED')) {
|
||||
? ' rowspan="2"'
|
||||
: '';
|
||||
}
|
||||
$text_url = 'sql.php3'
|
||||
. '?lang=' . $lang
|
||||
. '&convcharset=' . $convcharset
|
||||
. '&server=' . $server
|
||||
. '&db=' . urlencode($db)
|
||||
. '&table=' . urlencode($table)
|
||||
$text_url = 'sql.php3?'
|
||||
. PMA_generate_common_url($db, $table)
|
||||
. '&sql_query=' . urlencode($sql_query)
|
||||
. '&pos=' . $pos
|
||||
. '&session_max_rows=' . $session_max_rows
|
||||
@@ -634,11 +606,7 @@ if (!defined('PMA_DISPLAY_TBL_LIB_INCLUDED')) {
|
||||
} else {
|
||||
$sorted_sql_query = $unsorted_sql_query . $sort_order;
|
||||
}
|
||||
$url_query = 'lang=' . $lang
|
||||
. '&convcharset=' . $convcharset
|
||||
. '&server=' . $server
|
||||
. '&db=' . urlencode($db)
|
||||
. '&table=' . urlencode($table)
|
||||
$url_query = PMA_generate_common_url($db, $table)
|
||||
. '&pos=' . $pos
|
||||
. '&session_max_rows=' . $session_max_rows
|
||||
. '&disp_direction=' . $disp_direction
|
||||
@@ -914,11 +882,7 @@ if (!defined('PMA_DISPLAY_TBL_LIB_INCLUDED')) {
|
||||
} // end if (1.1)
|
||||
|
||||
// 1.2 Defines the urls for the modify/delete link(s)
|
||||
$url_query = 'lang=' . $lang
|
||||
. '&convcharset=' . $convcharset
|
||||
. '&server=' . $server
|
||||
. '&db=' . urlencode($db)
|
||||
. '&table=' . urlencode($table)
|
||||
$url_query = PMA_generate_common_url($db, $table)
|
||||
. '&pos=' . $pos
|
||||
. '&session_max_rows=' . $session_max_rows
|
||||
. '&disp_direction=' . $disp_direction
|
||||
@@ -963,11 +927,8 @@ if (!defined('PMA_DISPLAY_TBL_LIB_INCLUDED')) {
|
||||
. '?' . str_replace('&', '&', $url_query)
|
||||
. '&sql_query=' . urlencode($sql_query)
|
||||
. '&goto=main.php3';
|
||||
$del_url = 'sql.php3'
|
||||
. '?lang=' . $lang
|
||||
. '&convcharset=' . $convcharset
|
||||
. '&server=' . $server
|
||||
. '&db=mysql'
|
||||
$del_url = 'sql.php3?'
|
||||
. PMA_generate_common_url('mysql')
|
||||
. '&sql_query=' . urlencode('KILL ' . $row['Id'])
|
||||
. '&goto=' . urlencode($lnk_goto);
|
||||
$js_conf = 'KILL ' . $row['Id'];
|
||||
@@ -1051,9 +1012,7 @@ if (!defined('PMA_DISPLAY_TBL_LIB_INCLUDED')) {
|
||||
$title = (!empty($dispval))? ' title="' . htmlspecialchars($dispval) . '"' : '';
|
||||
|
||||
$vertical_display['data'][$row_no][$i] .= '<a href="sql.php3?'
|
||||
. 'lang=' . $lang . '&server=' . $server
|
||||
. '&convcharset=' . $convcharset
|
||||
. '&db=' . urlencode($db) . '&table=' . urlencode($map[$meta->name][0])
|
||||
. PMA_generate_common_url($db, $map[$meta->name][0])
|
||||
. '&pos=0&session_max_rows=' . $session_max_rows . '&dontlimitchars=' . $dontlimitchars
|
||||
. '&sql_query=' . urlencode('SELECT * FROM ' . PMA_backquote($map[$meta->name][0]) . ' WHERE ' . PMA_backquote($map[$meta->name][1]) . ' = ' . $row[$pointer]) . '"' . $title . '>'
|
||||
. $row[$pointer] . '</a>';
|
||||
@@ -1162,9 +1121,7 @@ if (!defined('PMA_DISPLAY_TBL_LIB_INCLUDED')) {
|
||||
$title = (!empty($dispval))? ' title="' . htmlspecialchars($dispval) . '"' : '';
|
||||
|
||||
$vertical_display['data'][$row_no][$i] .= '<a href="sql.php3?'
|
||||
. 'lang=' . $lang . '&convcharset=' . $convcharset
|
||||
. '&server=' . $server
|
||||
. '&db=' . urlencode($db) . '&table=' . urlencode($map[$meta->name][0])
|
||||
. PMA_generate_common_url($db, $map[$meta->name][0])
|
||||
. '&pos=0&session_max_rows=' . $session_max_rows . '&dontlimitchars=' . $dontlimitchars
|
||||
. '&sql_query=' . urlencode('SELECT * FROM ' . PMA_backquote($map[$meta->name][0]) . ' WHERE ' . PMA_backquote($map[$meta->name][1]) . ' = \'' . PMA_sqlAddslashes($relation_id) . '\'') . '"' . $title . '>'
|
||||
. $row[$pointer] . '</a>';
|
||||
|
46
libraries/url_generating.lib.php3
Normal file
46
libraries/url_generating.lib.php3
Normal file
@@ -0,0 +1,46 @@
|
||||
<?php
|
||||
/* $Id$ */
|
||||
// vim: expandtab sw=4 ts=4 sts=4:
|
||||
|
||||
|
||||
/**
|
||||
* URL/hidden inputs generating.
|
||||
*/
|
||||
|
||||
|
||||
if (!defined('PMA_URL_GENERATION_LIB_INCLUDED')){
|
||||
define('PMA_URL_GENERATION_LIB_INCLUDED', 1);
|
||||
|
||||
function PMA_generate_common_hidden_inputs ($db = '', $table = '')
|
||||
{
|
||||
global $lang, $convcharset, $server;
|
||||
global $cfg, $allow_recoding;
|
||||
|
||||
$result = '<input type="hidden" name="lang" value="' . $lang . '" />' . "\n" .
|
||||
'<input type="hidden" name="server" value="' . $server . '" />' . "\n";
|
||||
if (isset($cfg['AllowAnywhereRecoding']) && $cfg['AllowAnywhereRecoding'] && $allow_recoding)
|
||||
$result .= '<input type="hidden" name="convcharset" value="' . $convcharset . '" />' . "\n";
|
||||
if (!empty($db))
|
||||
$result .= '<input type="hidden" name="db" value="'.htmlspecialchars($db).'" />';
|
||||
if (!empty($table))
|
||||
$result .= '<input type="hidden" name="table" value="'.htmlspecialchars($table).'" />';
|
||||
return $result;
|
||||
}
|
||||
|
||||
function PMA_generate_common_url ($db = '', $table = '')
|
||||
{
|
||||
global $lang, $convcharset, $server;
|
||||
global $cfg, $allow_recoding;
|
||||
|
||||
$result = 'lang=' . $lang
|
||||
. '&server=' . $server;
|
||||
if (isset($cfg['AllowAnywhereRecoding']) && $cfg['AllowAnywhereRecoding'] && $allow_recoding)
|
||||
$result .= '&convcharset=' . $convcharset;
|
||||
if (!empty($db))
|
||||
$result .= '&db='.urlencode($db);
|
||||
if (!empty($table))
|
||||
$result .= '&table='.urlencode($table);
|
||||
return $result;
|
||||
}
|
||||
}
|
||||
?>
|
10
main.php3
10
main.php3
@@ -43,7 +43,7 @@ else if (isset($reload) && $reload) {
|
||||
?>
|
||||
<script type="text/javascript" language="javascript1.2">
|
||||
<!--
|
||||
window.parent.frames['nav'].location.replace('./left.php3?lang=<?php echo $lang; ?>&convcharset=<?php echo $convcharset; ?>&server=<?php echo $server; ?>');
|
||||
window.parent.frames['nav'].location.replace('./left.php3?<?php echo PMA_generate_common_url(); ?>');
|
||||
//-->
|
||||
</script>
|
||||
<?php
|
||||
@@ -92,7 +92,7 @@ if ($server > 0) {
|
||||
* Reload mysql (flush privileges)
|
||||
*/
|
||||
if (($server > 0) && isset($mode) && ($mode == 'reload')) {
|
||||
$result = PMA_mysql_query('FLUSH PRIVILEGES'); // Debug: or PMA_mysqlDie('', 'FLUSH PRIVILEGES', FALSE, 'main.php3?lang=' . $lang . '&server=' . $server);
|
||||
$result = PMA_mysql_query('FLUSH PRIVILEGES'); // Debug: or PMA_mysqlDie('', 'FLUSH PRIVILEGES', FALSE, 'main.php3?' . PMA_generate_common_url());
|
||||
echo '<p><b>';
|
||||
if ($result != 0) {
|
||||
echo $strMySQLReloaded;
|
||||
@@ -270,7 +270,7 @@ if ($server > 0) {
|
||||
$db_to_create = '';
|
||||
}
|
||||
|
||||
$common_url_query = 'lang=' . $lang . '&convcharset=' . $convcharset . '&server=' . $server;
|
||||
$common_url_query = PMA_generate_common_url();
|
||||
|
||||
if ($is_superuser) {
|
||||
$cfg['ShowMysqlInfo'] = TRUE;
|
||||
@@ -304,9 +304,7 @@ if ($server > 0) {
|
||||
<td>
|
||||
<form method="post" action="db_create.php3">
|
||||
<?php echo $strCreateNewDatabase . ' ' . PMA_showMySQLDocu('Reference', 'CREATE_DATABASE'); ?><br />
|
||||
<input type="hidden" name="server" value="<?php echo $server; ?>" />
|
||||
<input type="hidden" name="lang" value="<?php echo $lang; ?>" />
|
||||
<input type="hidden" name="convcharset" value="<?php echo $convcharset; ?>" />
|
||||
<?php echo PMA_generate_common_hidden_inputs(); ?>
|
||||
<input type="hidden" name="reload" value="1" />
|
||||
<input type="text" name="db" value="<?php echo $db_to_create; ?>" maxlength="64" class="textfield" />
|
||||
<input type="submit" value="<?php echo $strCreate; ?>" />
|
||||
|
@@ -107,16 +107,12 @@ if (!empty($submit_mult) && !empty($what)) {
|
||||
echo '<tt>' . $full_query . '</tt> ?<br/>' . "\n";
|
||||
?>
|
||||
<form action="<?php echo $action; ?>" method="post">
|
||||
<input type="hidden" name="lang" value="<?php echo $lang; ?>" />
|
||||
<input type="hidden" name="convcharset" value="<?php echo $convcharset; ?>" />
|
||||
<input type="hidden" name="server" value="<?php echo $server; ?>" />
|
||||
<?php
|
||||
echo "\n";
|
||||
if (strpos(' ' . $action, 'db_details') == 1) {
|
||||
echo ' <input type="hidden" name="db" value="' . htmlspecialchars($db) . '" />' . "\n";
|
||||
echo PMA_generate_common_hidden_inputs($db);
|
||||
} else if (strpos(' ' . $action, 'tbl_properties') == 1) {
|
||||
echo ' <input type="hidden" name="db" value="' . htmlspecialchars($db) . '" />' . "\n";
|
||||
echo ' <input type="hidden" name="table" value="' . htmlspecialchars($table) . '" />' . "\n";
|
||||
echo PMA_generate_common_hidden_inputs($db,$table);
|
||||
}
|
||||
for ($i = 0; $i < $selected_cnt; $i++) {
|
||||
echo ' <input type="hidden" name="selected[]" value="' . htmlspecialchars($selected[$i]) . '" />' . "\n";
|
||||
|
@@ -120,11 +120,7 @@ if ($cfgRelation['pdfwork']) {
|
||||
?>
|
||||
<form method="post" action="pdf_pages.php3" name="selpage">
|
||||
<?php echo $strChoosePage . "\n"; ?>
|
||||
<input type="hidden" name="db" value="<?php echo htmlspecialchars($db); ?>" />
|
||||
<input type="hidden" name="lang" value="<?php echo $lang; ?>" />
|
||||
<input type="hidden" name="convcharset" value="<?php echo $convcharset; ?>" />
|
||||
<input type="hidden" name="server" value="<?php echo $server; ?>" />
|
||||
<input type="hidden" name="table" value="<?php echo htmlspecialchars($table); ?>" />
|
||||
<?php echo PMA_generate_common_hidden_inputs($db, $table); ?>
|
||||
<input type="hidden" name="do" value="choosepage" />
|
||||
<select name="chpage" onchange="this.form.submit()">
|
||||
<?php
|
||||
@@ -149,11 +145,7 @@ if ($cfgRelation['pdfwork']) {
|
||||
?>
|
||||
<form method="post" action="pdf_pages.php3" name="crpage">
|
||||
<?php echo $strCreatePage . "\n"; ?>
|
||||
<input type="hidden" name="lang" value="<?php echo $lang; ?>" />
|
||||
<input type="hidden" name="convcharset" value="<?php echo $convcharset; ?>" />
|
||||
<input type="hidden" name="server" value="<?php echo $server; ?>" />
|
||||
<input type="hidden" name="db" value="<?php echo htmlspecialchars($db); ?>" />
|
||||
<input type="hidden" name="table" value="<?php echo htmlspecialchars($table); ?>" />
|
||||
<?php echo PMA_generate_common_hidden_inputs($db, $table); ?>
|
||||
<input type="hidden" name="do" value="createpage" />
|
||||
<input type="text" name="newpage" size="20" maxlength="50" />
|
||||
<input type="submit" value="<?php echo $strGo; ?>" />
|
||||
@@ -168,11 +160,7 @@ if ($cfgRelation['pdfwork']) {
|
||||
|
||||
<h2><?php echo $strSelectTables ;?></h2>
|
||||
<form method="post" action="pdf_pages.php3" name="edcoord">
|
||||
<input type="hidden" name="lang" value="<?php echo $lang; ?>" />
|
||||
<input type="hidden" name="convcharset" value="<?php echo $convcharset; ?>" />
|
||||
<input type="hidden" name="server" value="<?php echo $server; ?>" />
|
||||
<input type="hidden" name="db" value="<?php echo htmlspecialchars($db); ?>" />
|
||||
<input type="hidden" name="table" value="<?php echo htmlspecialchars($table); ?>" />
|
||||
<?php echo PMA_generate_common_hidden_inputs($db, $table); ?>
|
||||
<input type="hidden" name="chpage" value="<?php echo $chpage; ?>" />
|
||||
<input type="hidden" name="do" value="edcoord" />
|
||||
<table border="0">
|
||||
@@ -261,10 +249,7 @@ if ($cfgRelation['pdfwork']) {
|
||||
if (isset($do) && ($do == 'edcoord' || $do == 'choosepage')) {
|
||||
?>
|
||||
<form method="post" action="pdf_schema.php3">
|
||||
<input type="hidden" name="server" value="<?php echo $server; ?>" />
|
||||
<input type="hidden" name="lang" value="<?php echo $lang; ?>" />
|
||||
<input type="hidden" name="convcharset" value="<?php echo $convcharset; ?>" />
|
||||
<input type="hidden" name="db" value="<?php echo htmlspecialchars($db); ?>" />
|
||||
<?php echo PMA_generate_common_hidden_inputs($db); ?>
|
||||
<input type="hidden" name="pdf_page_number" value="<?php echo $chpage; ?>" />
|
||||
<?php echo $strDisplayPDF; ?> :<br />
|
||||
<input type="checkbox" name="show_grid" id="show_grid_opt" />
|
||||
|
@@ -296,11 +296,7 @@ class PMA_PDF extends FPDF
|
||||
echo ' ' . $error_message . "\n";
|
||||
echo '</p>' . "\n";
|
||||
|
||||
echo '<a href="db_details_structure.php3'
|
||||
. '?lang=' . $lang
|
||||
. '&convcharset=' . $convcharset
|
||||
. '&server=' . $server
|
||||
. '&db=' . urlencode($db)
|
||||
echo '<a href="db_details_structure.php3?' . PMA_generate_common_url($db)
|
||||
. '">' . $GLOBALS['strBack'] . '</a>';
|
||||
echo "\n";
|
||||
|
||||
|
@@ -237,10 +237,7 @@ if (!isset($goto)
|
||||
$goto = 'db_details.php3';
|
||||
}
|
||||
$err_url = $goto
|
||||
. '?lang=' . $lang
|
||||
. '&convcharset=' . $convcharset
|
||||
. '&server=' . $server
|
||||
. '&db=' . urlencode($db)
|
||||
. '?' . PMA_generate_common_url($db)
|
||||
. (($goto == 'tbl_properties.php3') ? '&table=' . urlencode($table) : '');
|
||||
|
||||
|
||||
|
@@ -25,9 +25,7 @@ if (isset($table)) {
|
||||
/**
|
||||
* Set parameters for links
|
||||
*/
|
||||
$url_query = 'lang=' . $lang
|
||||
. '&convcharset=' . $convcharset
|
||||
. '&server=' . $server;
|
||||
$url_query = PMA_generate_common_url();
|
||||
|
||||
/**
|
||||
* Defines the urls to return to in case of error in a sql statement
|
||||
|
@@ -590,11 +590,9 @@ if (empty($adduser)) {
|
||||
. ' Please run the script <tt>mysql_fix_privilege_tables</tt> that should be included in your MySQL server distribution to solve this problem!' . "\n"
|
||||
. '</div><br />' . "\n";
|
||||
}
|
||||
echo '<form name="usersForm" action="server_privileges.php3" method="post" />' . "\n"
|
||||
. ' <input type="hidden" name="lang" value="' . $lang . '" />' . "\n"
|
||||
. ' <input type="hidden" name="convcharset" value="' . $convcharset . '" />' . "\n"
|
||||
. ' <input type="hidden" name="server" value="' . $server . '" />' . "\n"
|
||||
. ' <table border="0">' . "\n"
|
||||
echo '<form name="usersForm" action="server_privileges.php3" method="post" />' . "\n";
|
||||
echo PMA_generate_common_hidden_inputs();
|
||||
echo ' <table border="0">' . "\n"
|
||||
. ' <tr>' . "\n"
|
||||
. ' <th></th>' . "\n"
|
||||
. ' <th> ' . $strUser . ' </th>' . "\n"
|
||||
@@ -688,11 +686,9 @@ if (empty($adduser)) {
|
||||
unset($res);
|
||||
echo '<ul>' . "\n"
|
||||
. ' <li>' . "\n"
|
||||
. ' <form action="server_privileges.php3" method="post">' . "\n"
|
||||
. ' <input type="hidden" name="lang" value="' . $lang . '" />' . "\n"
|
||||
. ' <input type="hidden" name="convcharset" value="' . $convcharset . '" />' . "\n"
|
||||
. ' <input type="hidden" name="server" value="' . $server . '" />' . "\n"
|
||||
. ' <input type="hidden" name="username" value="' . htmlspecialchars($username) . '" />' . "\n";
|
||||
. ' <form action="server_privileges.php3" method="post">' . "\n";
|
||||
echo PMA_generate_common_hidden_inputs();
|
||||
echo ' <input type="hidden" name="username" value="' . htmlspecialchars($username) . '" />' . "\n";
|
||||
if ($hostname != '%') {
|
||||
echo ' <input type="hidden" name="hostname" value="' . htmlspecialchars($hostname) . '" />' . "\n";
|
||||
}
|
||||
@@ -803,11 +799,9 @@ if (empty($adduser)) {
|
||||
unset($row);
|
||||
echo ' <tr>' . "\n"
|
||||
. ' <td colspan="' .(PMA_MYSQL_INT_VERSION >= 32211 ? '5' : '4') . '">' . "\n"
|
||||
. ' <form action="server_privileges.php3" method="post">' . "\n"
|
||||
. ' <input type="hidden" name="lang" value="' . $lang . '" />' . "\n"
|
||||
. ' <input type="hidden" name="convcharset" value="' . $convcharset . '" />' . "\n"
|
||||
. ' <input type="hidden" name="server" value="' . $server . '" />' . "\n"
|
||||
. ' <input type="hidden" name="username" value="' . htmlspecialchars($username) . '" />' . "\n";
|
||||
. ' <form action="server_privileges.php3" method="post">' . "\n";
|
||||
echo PMA_generate_common_hidden_inputs();
|
||||
echo ' <input type="hidden" name="username" value="' . htmlspecialchars($username) . '" />' . "\n";
|
||||
if ($hostname != '%') {
|
||||
echo ' <input type="hidden" name="hostname" value="' . htmlspecialchars($hostname) . '" />' . "\n";
|
||||
}
|
||||
@@ -828,11 +822,9 @@ if (empty($adduser)) {
|
||||
}
|
||||
if (empty($dbname)) {
|
||||
echo ' <li>' . "\n"
|
||||
. ' <form action="server_privileges.php3" method="post" onsubmit="checkPassword(this);">' . "\n"
|
||||
. ' <input type="hidden" name="lang" value="' . $lang . '" />' . "\n"
|
||||
. ' <input type="hidden" name="convcharset" value="' . $convcharset . '" />' . "\n"
|
||||
. ' <input type="hidden" name="server" value="' . $server . '" />' . "\n"
|
||||
. ' <input type="hidden" name="username" value="' . htmlspecialchars($username) . '" />' . "\n";
|
||||
. ' <form action="server_privileges.php3" method="post" onsubmit="checkPassword(this);">' . "\n";
|
||||
echo PMA_generate_common_hidden_inputs();
|
||||
echo ' <input type="hidden" name="username" value="' . htmlspecialchars($username) . '" />' . "\n";
|
||||
if ($hostname != '%') {
|
||||
echo ' <input type="hidden" name="hostname" value="' . htmlspecialchars($hostname) . '" />' . "\n";
|
||||
}
|
||||
@@ -870,11 +862,9 @@ if (empty($adduser)) {
|
||||
echo '<h2>' . "\n"
|
||||
. ' ' . $strAddUser . "\n"
|
||||
. '</h2>' . "\n"
|
||||
. '<form action="server_privileges.php3" method="post" onsubmit="return checkAddUser(this);">' . "\n"
|
||||
. ' <input type="hidden" name="lang" value="' . $lang . '" />' . "\n"
|
||||
. ' <input type="hidden" name="convcharset" value="' . $convcharset . '" />' . "\n"
|
||||
. ' <input type="hidden" name="server" value="' . $server . '" />' . "\n"
|
||||
. ' <table border="0">' . "\n"
|
||||
. '<form action="server_privileges.php3" method="post" onsubmit="return checkAddUser(this);">' . "\n";
|
||||
echo PMA_generate_common_hidden_inputs();
|
||||
echo ' <table border="0">' . "\n"
|
||||
. ' <tr>' . "\n"
|
||||
. ' <th colspan="3">' . "\n"
|
||||
. ' ' . $strLoginInformation . "\n"
|
||||
|
51
sql.php3
51
sql.php3
@@ -27,10 +27,7 @@ if (empty($goto)) {
|
||||
} // end if
|
||||
if (!isset($err_url)) {
|
||||
$err_url = (!empty($back) ? $back : $goto)
|
||||
. '?lang=' . $lang
|
||||
. '&convcharset=' . $convcharset
|
||||
. '&server=' . $server
|
||||
. (isset($db) ? '&db=' . urlencode($db) : '')
|
||||
. '?' . PMA_generate_common_url(isset($db) ? $db : '')
|
||||
. ((strpos(' ' . $goto, 'db_details') != 1 && isset($table)) ? '&table=' . urlencode($table) : '');
|
||||
} // end if
|
||||
|
||||
@@ -123,12 +120,8 @@ if ($is_select) {
|
||||
* Sets or modifies the $goto variable if required
|
||||
*/
|
||||
if ($goto == 'sql.php3') {
|
||||
$goto = 'sql.php3'
|
||||
. '?lang=' . $lang
|
||||
. '&convcharset=' . $convcharset
|
||||
. '&server=' . $server
|
||||
. '&db=' . urlencode($db)
|
||||
. '&table=' . urlencode($table)
|
||||
$goto = 'sql.php3?'
|
||||
. PMA_generate_common_url($db, $table)
|
||||
. '&pos=' . $pos
|
||||
. '&sql_query=' . urlencode($sql_query);
|
||||
} // end if
|
||||
@@ -182,11 +175,7 @@ if ($do_confirm) {
|
||||
echo '<tt>' . htmlspecialchars($stripped_sql_query) . '</tt> ?<br/>' . "\n";
|
||||
?>
|
||||
<form action="sql.php3" method="post">
|
||||
<input type="hidden" name="lang" value="<?php echo $lang; ?>" />
|
||||
<input type="hidden" name="convcharset" value="<?php echo $convcharset; ?>" />
|
||||
<input type="hidden" name="server" value="<?php echo $server; ?>" />
|
||||
<input type="hidden" name="db" value="<?php echo htmlspecialchars($db); ?>" />
|
||||
<input type="hidden" name="table" value="<?php echo isset($table) ? htmlspecialchars($table) : ''; ?>" />
|
||||
<?php echo PMA_generate_common_hidden_inputs($db, $table); ?>
|
||||
<input type="hidden" name="sql_query" value="<?php echo urlencode(addslashes($sql_query)); ?>" />
|
||||
<input type="hidden" name="zero_rows" value="<?php echo isset($zero_rows) ? $zero_rows : ''; ?>" />
|
||||
<input type="hidden" name="goto" value="<?php echo $goto; ?>" />
|
||||
@@ -508,23 +497,16 @@ else {
|
||||
|
||||
// Displays "Insert a new row" link if required
|
||||
if ($disp_mode[6] == '1') {
|
||||
$lnk_goto = 'sql.php3'
|
||||
. '?lang=' . $lang
|
||||
. '&convcharset=' . $convcharset
|
||||
. '&server=' . $server
|
||||
. '&db=' . urlencode($db)
|
||||
. '&table=' . urlencode($table)
|
||||
$lnk_goto = 'sql.php3?'
|
||||
. PMA_generate_common_url($db, $table)
|
||||
. '&pos=' . $pos
|
||||
. '&session_max_rows=' . $session_max_rows
|
||||
. '&disp_direction=' . $disp_direction
|
||||
. '&repeat_cells=' . $repeat_cells
|
||||
. '&dontlimitchars=' . $dontlimitchars
|
||||
. '&sql_query=' . urlencode($sql_query);
|
||||
$url_query = '?lang=' . $lang
|
||||
. '&convcharset=' . $convcharset
|
||||
. '&server=' . $server
|
||||
. '&db=' . urlencode($db)
|
||||
. '&table=' . urlencode($table)
|
||||
$url_query = '?'
|
||||
. PMA_generate_common_url($db, $table)
|
||||
. '&pos=' . $pos
|
||||
. '&session_max_rows=' . $session_max_rows
|
||||
. '&disp_direction=' . $disp_direction
|
||||
@@ -543,11 +525,8 @@ else {
|
||||
|
||||
// Displays "printable view" link if required
|
||||
if ($disp_mode[9] == '1') {
|
||||
$url_query = '?lang=' . $lang
|
||||
. '&convcharset=' . $convcharset
|
||||
. '&server=' . $server
|
||||
. '&db=' . urlencode($db)
|
||||
. '&table=' . urlencode($table)
|
||||
$url_query = '?'
|
||||
. PMA_generate_common_url($db, $table)
|
||||
. '&pos=' . $pos
|
||||
. '&session_max_rows=' . $session_max_rows
|
||||
. '&disp_direction=' . $disp_direction
|
||||
@@ -568,12 +547,8 @@ else {
|
||||
&& !empty($sql_query)) {
|
||||
echo "\n";
|
||||
|
||||
$goto = 'sql.php3'
|
||||
. '?lang=' . $lang
|
||||
. '&convcharset=' . $convcharset
|
||||
. '&server=' . $server
|
||||
. '&db=' . urlencode($db)
|
||||
. '&table=' . urlencode($table)
|
||||
$goto = 'sql.php3?'
|
||||
. PMA_generate_common_url($db, $table)
|
||||
. '&pos=' . $pos
|
||||
. '&session_max_rows=' . $session_max_rows
|
||||
. '&disp_direction=' . $disp_direction
|
||||
@@ -592,7 +567,7 @@ else {
|
||||
?>
|
||||
<br /><br />
|
||||
<?php echo $strBookmarkLabel; ?> :
|
||||
<input type="hidden" name="server" value="<?php echo $server; ?>" />
|
||||
<?php echo PMA_generate_common_hidden_inputs(); ?>
|
||||
<input type="hidden" name="goto" value="<?php echo $goto; ?>" />
|
||||
<input type="hidden" name="fields[dbase]" value="<?php echo htmlspecialchars($db); ?>" />
|
||||
<input type="hidden" name="fields[user]" value="<?php echo $cfg['Bookmark']['user']; ?>" />
|
||||
|
@@ -16,12 +16,7 @@ require('./header.inc.php3');
|
||||
/**
|
||||
* Defines the url to return to in case of error in a sql statement
|
||||
*/
|
||||
$err_url = 'tbl_properties.php3'
|
||||
. '?lang=' . $lang
|
||||
. '&convcharset=' . $convcharset
|
||||
. '&server=' . $server
|
||||
. '&db=' . urlencode($db)
|
||||
. '&table=' . urlencode($table);
|
||||
$err_url = 'tbl_properties.php3?' . PMA_generate_common_url($db, $table);
|
||||
|
||||
|
||||
/**
|
||||
|
@@ -18,12 +18,7 @@ if (!isset($submit_mult)) {
|
||||
/**
|
||||
* Defines the url to return to in case of error in a sql statement
|
||||
*/
|
||||
$err_url = 'tbl_properties_structure.php3'
|
||||
. '?lang=' . $lang
|
||||
. '&convcharset=' . $convcharset
|
||||
. '&server=' . $server
|
||||
. '&db=' . urlencode($db)
|
||||
. '&table=' . urlencode($table);
|
||||
$err_url = 'tbl_properties_structure.php3?' . PMA_generate_common_url($db, $table);
|
||||
|
||||
|
||||
/**
|
||||
|
@@ -18,12 +18,8 @@ require('./libraries/relation.lib.php3'); // foreign keys
|
||||
if (!empty($message)) {
|
||||
if (isset($goto)) {
|
||||
$goto_cpy = $goto;
|
||||
$goto = 'tbl_properties.php3'
|
||||
. '?lang=' . $lang
|
||||
. '&convcharset=' . $convcharset
|
||||
. '&server=' . $server
|
||||
. '&db=' . urlencode($db)
|
||||
. '&table=' . urlencode($table)
|
||||
$goto = 'tbl_properties.php3?'
|
||||
. PMA_generate_common_url($db, $table)
|
||||
. '&$show_query=1'
|
||||
. '&sql_query=' . urlencode($disp_query);
|
||||
} else {
|
||||
@@ -66,11 +62,8 @@ if (!isset($goto)) {
|
||||
if (!ereg('^(db_details|tbl_properties|tbl_select)', $goto)) {
|
||||
$err_url = $goto;
|
||||
} else {
|
||||
$err_url = $goto
|
||||
. '?lang=' . $lang
|
||||
. '&convcharset=' . $convcharset
|
||||
. '&server=' . $server
|
||||
. '&db=' . urlencode($db)
|
||||
$err_url = $goto . '?'
|
||||
. PMA_generate_common_url($db)
|
||||
//. (($goto == 'tbl_properties.php3') ? '&table=' . urlencode($table) : '');
|
||||
. ((ereg('^(tbl_properties|tbl_select)', $goto)) ? '&table=' . urlencode($table) : '');
|
||||
}
|
||||
@@ -85,11 +78,7 @@ require('./libraries/db_table_exists.lib.php3');
|
||||
/**
|
||||
* Sets parameters for links and displays top menu
|
||||
*/
|
||||
$url_query = 'lang=' . $lang
|
||||
. '&convcharset=' . $convcharset
|
||||
. '&server=' . $server
|
||||
. '&db=' . urlencode($db)
|
||||
. '&table=' . urlencode($table)
|
||||
$url_query = PMA_generate_common_url($db, $table)
|
||||
. '&goto=tbl_properties.php3';
|
||||
|
||||
require('./tbl_properties_table_info.php3');
|
||||
@@ -110,12 +99,8 @@ if (isset($primary_key)) {
|
||||
unset($row);
|
||||
unset($primary_key);
|
||||
$goto_cpy = $goto;
|
||||
$goto = 'tbl_properties.php3'
|
||||
. '?lang=' . $lang
|
||||
. '&convcharset=' . $convcharset
|
||||
. '&server=' . $server
|
||||
. '&db=' . urlencode($db)
|
||||
. '&table=' . urlencode($table)
|
||||
$goto = 'tbl_properties.php3?'
|
||||
. PMA_generate_common_url($db, $table)
|
||||
. '&$show_query=1'
|
||||
. '&sql_query=' . urlencode($local_query);
|
||||
if (isset($sql_query)) {
|
||||
@@ -159,11 +144,7 @@ $chg_evt_handler = (PMA_USR_BROWSER_AGENT == 'IE' && PMA_USR_BROWSER_VER >= 5)
|
||||
|
||||
<!-- Change table properties form -->
|
||||
<form method="post" action="tbl_replace.php3" name="insertForm">
|
||||
<input type="hidden" name="lang" value="<?php echo $lang; ?>" />
|
||||
<input type="hidden" name="convcharset" value="<?php echo $convcharset; ?>" />
|
||||
<input type="hidden" name="server" value="<?php echo $server; ?>" />
|
||||
<input type="hidden" name="db" value="<?php echo htmlspecialchars($db); ?>" />
|
||||
<input type="hidden" name="table" value="<?php echo $table; ?>" />
|
||||
<?php echo PMA_generate_common_hidden_inputs($db, $table); ?>
|
||||
<input type="hidden" name="goto" value="<?php echo $goto; ?>" />
|
||||
<input type="hidden" name="pos" value="<?php echo isset($pos) ? $pos : 0; ?>" />
|
||||
<input type="hidden" name="session_max_rows" value="<?php echo isset($session_max_rows) ? $session_max_rows : ''; ?>" />
|
||||
|
@@ -16,12 +16,7 @@ require('./header.inc.php3');
|
||||
/**
|
||||
* Defines the url to return to in case of error in a sql statement
|
||||
*/
|
||||
$err_url = 'tbl_properties.php3'
|
||||
. '?lang=' . $lang
|
||||
. '&convcharset=' . $convcharset
|
||||
. '&server=' . $server
|
||||
. '&db=' . urlencode($db)
|
||||
. '&table=' . urlencode($table);
|
||||
$err_url = 'tbl_properties.php3?' . PMA_generate_common_url($db, $table);
|
||||
|
||||
|
||||
/**
|
||||
|
@@ -67,12 +67,7 @@ require('./libraries/zip.lib.php3');
|
||||
/**
|
||||
* Defines the url to return to in case of error in a sql statement
|
||||
*/
|
||||
$err_url = 'tbl_properties.php3'
|
||||
. '?lang=' . $lang
|
||||
. '&convcharset=' . $convcharset
|
||||
. '&server=' . $server
|
||||
. '&db=' . urlencode($db)
|
||||
. (isset($table) ? '&table=' . urlencode($table) : '');
|
||||
$err_url = 'tbl_properties.php3?' . PMA_generate_common_url($db, isset($table) ? $table : '');
|
||||
|
||||
|
||||
/**
|
||||
|
@@ -40,7 +40,7 @@ if (!defined('PMA_IDX_INCLUDED')) {
|
||||
$is_db = @PMA_mysql_select_db($db);
|
||||
}
|
||||
if (empty($db) || !$is_db) {
|
||||
header('Location: ' . $cfg['PmaAbsoluteUri'] . 'main.php3?lang=' . $lang . '&convcharset=' . $convcharset . '&server=' . $server . (isset($message) ? '&message=' . urlencode($message) : '') . '&reload=1');
|
||||
header('Location: ' . $cfg['PmaAbsoluteUri'] . 'main.php3?' . PMA_generate_common_url() . (isset($message) ? '&message=' . urlencode($message) : '') . '&reload=1');
|
||||
exit();
|
||||
}
|
||||
// Not a valid table name -> back to the default db_details sub-page
|
||||
@@ -49,7 +49,7 @@ if (!defined('PMA_IDX_INCLUDED')) {
|
||||
}
|
||||
if (empty($table)
|
||||
|| !($is_table && @mysql_numrows($is_table))) {
|
||||
header('Location: ' . $cfg['PmaAbsoluteUri'] . $cfg['DefaultTabDatabase'] . '?lang=' . $lang . '&convcharset=' . $convcharset . '&server=' . $server .'&db=' . urlencode($db) . (isset($message) ? '&message=' . urlencode($message) : '') . '&reload=1');
|
||||
header('Location: ' . $cfg['PmaAbsoluteUri'] . $cfg['DefaultTabDatabase'] . '?' . PMA_generate_common_url($db) . (isset($message) ? '&message=' . urlencode($message) : '') . '&reload=1');
|
||||
exit();
|
||||
} else if (isset($is_table)) {
|
||||
mysql_free_result($is_table);
|
||||
@@ -65,11 +65,7 @@ if (!defined('PMA_IDX_INCLUDED')) {
|
||||
* Gets fields and indexes informations
|
||||
*/
|
||||
if (defined('PMA_IDX_INCLUDED')) {
|
||||
$err_url_0 = 'db_details.php3'
|
||||
. '?lang=' . $lang
|
||||
. '&convcharset=' . $convcharset
|
||||
. '&server=' . $server
|
||||
. '&db=' . urlencode($db);
|
||||
$err_url_0 = 'db_details.php3?' . PMA_generate_common_url($db);
|
||||
}
|
||||
|
||||
// Gets table keys and store them in arrays
|
||||
@@ -167,12 +163,7 @@ if (get_magic_quotes_gpc()) {
|
||||
if (!defined('PMA_IDX_INCLUDED')
|
||||
&& (isset($index) && isset($do_save_data))) {
|
||||
|
||||
$err_url = 'tbl_indexes.php3'
|
||||
. '?lang=' . $lang
|
||||
. '&convcharset=' . $convcharset
|
||||
. '&server=' . $server
|
||||
. '&db=' . urlencode($db)
|
||||
. '&table=' . urlencode($table);
|
||||
$err_url = 'tbl_indexes.php3?' . PMA_generate_common_url($db, $table);
|
||||
if (empty($old_index)) {
|
||||
$err_url .= '&create_index=1&idx_num_fields=' . $idx_num_fields;
|
||||
} else {
|
||||
@@ -306,11 +297,7 @@ else if (!defined('PMA_IDX_INCLUDED')
|
||||
<!-- Build index form -->
|
||||
<form action="tbl_indexes.php3" method="post" name="index_frm"
|
||||
onsubmit="if (typeof(this.elements['index'].disabled) != 'undefined') {this.elements['index'].disabled = false}">
|
||||
<input type="hidden" name="lang" value="<?php echo $lang; ?>" />
|
||||
<input type="hidden" name="convcharset" value="<?php echo $convcharset; ?>" />
|
||||
<input type="hidden" name="server" value="<?php echo $server; ?>" />
|
||||
<input type="hidden" name="db" value="<?php echo htmlspecialchars($db); ?>" />
|
||||
<input type="hidden" name="table" value="<?php echo htmlspecialchars($table); ?>" />
|
||||
<?php echo PMA_generate_common_hidden_inputs($db, $table); ?>
|
||||
<?php
|
||||
if (isset($create_index)) {
|
||||
echo '<input type="hidden" name="create_index" value="1" />';
|
||||
@@ -424,11 +411,7 @@ else if (!defined('PMA_IDX_INCLUDED')
|
||||
?>
|
||||
<!-- Indexes form -->
|
||||
<form action="tbl_indexes.php3" method="post">
|
||||
<input type="hidden" name="lang" value="<?php echo $lang; ?>" />
|
||||
<input type="hidden" name="convcharset" value="<?php echo $convcharset; ?>" />
|
||||
<input type="hidden" name="server" value="<?php echo $server; ?>" />
|
||||
<input type="hidden" name="db" value="<?php echo htmlspecialchars($db); ?>" />
|
||||
<input type="hidden" name="table" value="<?php echo htmlspecialchars($table); ?>" />
|
||||
<?php echo PMA_generate_common_hidden_inputs($db, $table); ?>
|
||||
<?php
|
||||
echo "\n";
|
||||
echo ' ' . $strIndexes . ' :' . "\n";
|
||||
|
@@ -34,12 +34,7 @@ require('./libraries/common.lib.php3');
|
||||
/**
|
||||
* Defines the url to return to in case of error in a sql statement
|
||||
*/
|
||||
$err_url = 'tbl_properties.php3'
|
||||
. '?lang=' . $lang
|
||||
. '&convcharset=' . $convcharset
|
||||
. '&server=' . $server
|
||||
. '&db=' . urlencode($db)
|
||||
. '&table=' . urlencode($table);
|
||||
$err_url = 'tbl_properties.ph3?' . PMA_generate_common_url($db, $table);
|
||||
|
||||
|
||||
/**
|
||||
|
@@ -22,18 +22,9 @@ $cfgRelation = PMA_getRelationsParam();
|
||||
* Defines the url to return to in case of error in a sql statement
|
||||
*/
|
||||
if (isset($table)) {
|
||||
$err_url = 'tbl_properties.php3'
|
||||
. '?lang=' . $lang
|
||||
. '&convcharset=' . $convcharset
|
||||
. '&server=' . $server
|
||||
. '&db=' . urlencode($db)
|
||||
. '&table=' . urlencode($table);
|
||||
$err_url = 'tbl_properties.php3?' . PMA_generate_common_url($db, $table);
|
||||
} else {
|
||||
$err_url = 'db_details.php3'
|
||||
. '?lang=' . $lang
|
||||
. '&convcharset=' . $convcharset
|
||||
. '&server=' . $server
|
||||
. '&db=' . urlencode($db);
|
||||
$err_url = 'db_details.php3?' . PMA_generate_common_url($db);
|
||||
}
|
||||
|
||||
|
||||
|
@@ -5,12 +5,8 @@
|
||||
|
||||
?>
|
||||
<form method="post" action="<?php echo $action; ?>">
|
||||
<input type="hidden" name="server" value="<?php echo $server; ?>" />
|
||||
<input type="hidden" name="lang" value="<?php echo $lang; ?>" />
|
||||
<input type="hidden" name="convcharset" value="<?php echo $convcharset; ?>" />
|
||||
<input type="hidden" name="db" value="<?php echo htmlspecialchars($db); ?>" />
|
||||
<input type="hidden" name="table" value="<?php echo htmlspecialchars($table); ?>" />
|
||||
<?php
|
||||
echo PMA_generate_common_hidden_inputs($db, $table);
|
||||
if ($action == 'tbl_create.php3') {
|
||||
?>
|
||||
<input type="hidden" name="reload" value="1" />
|
||||
|
@@ -20,17 +20,8 @@ if (!defined('PMA_BOOKMARK_LIB_INCLUDED')) {
|
||||
/**
|
||||
* Defines the urls to return to in case of error in a sql statement
|
||||
*/
|
||||
$err_url_0 = $cfg['DefaultTabDatabase']
|
||||
. '?lang=' . $lang
|
||||
. '&convcharset=' . $convcharset
|
||||
. '&server=' . $server
|
||||
. '&db=' . urlencode($db);
|
||||
$err_url = $cfg['DefaultTabTable']
|
||||
. '?lang=' . $lang
|
||||
. '&convcharset=' . $convcharset
|
||||
. '&server=' . $server
|
||||
. '&db=' . urlencode($db)
|
||||
. '&table=' . urlencode($table);
|
||||
$err_url_0 = $cfg['DefaultTabDatabase'] . '?' . PMA_generate_common_url($db);
|
||||
$err_url = $cfg['DefaultTabTable'] . '?' . PMA_generate_common_url($db, $table);
|
||||
|
||||
|
||||
/**
|
||||
@@ -53,10 +44,6 @@ if (!isset($message)) {
|
||||
/**
|
||||
* Set parameters for links
|
||||
*/
|
||||
$url_query = 'lang=' . $lang
|
||||
. '&convcharset=' . $convcharset
|
||||
. '&server=' . $server
|
||||
. '&db=' . urlencode($db)
|
||||
. '&table=' . urlencode($table);
|
||||
$url_query = PMA_generate_common_url($db, $table);
|
||||
|
||||
?>
|
||||
|
@@ -17,11 +17,7 @@ require('./tbl_properties_table_info.php3');
|
||||
</p>
|
||||
|
||||
<form method="post" action="tbl_dump.php3" name="tbl_dump">
|
||||
<input type="hidden" name="server" value="<?php echo $server; ?>" />
|
||||
<input type="hidden" name="lang" value="<?php echo $lang; ?>" />
|
||||
<input type="hidden" name="convcharset" value="<?php echo $convcharset; ?>" />
|
||||
<input type="hidden" name="db" value="<?php echo htmlspecialchars($db); ?>" />
|
||||
<input type="hidden" name="table" value="<?php echo htmlspecialchars($table); ?>" />
|
||||
<?php echo PMA_generate_common_hidden_inputs($db, $table); ?>
|
||||
<table cellpadding="5" border="2" align="center">
|
||||
<tr>
|
||||
|
||||
|
@@ -58,11 +58,7 @@ if (PMA_MYSQL_INT_VERSION >= 32334) {
|
||||
<!-- Order the table -->
|
||||
<li>
|
||||
<form method="post" action="tbl_properties_operations.php3">
|
||||
<input type="hidden" name="server" value="<?php echo $server; ?>" />
|
||||
<input type="hidden" name="lang" value="<?php echo $lang; ?>" />
|
||||
<input type="hidden" name="convcharset" value="<?php echo $convcharset; ?>" />
|
||||
<input type="hidden" name="db" value="<?php echo htmlspecialchars($db); ?>" />
|
||||
<input type="hidden" name="table" value="<?php echo htmlspecialchars($table); ?>" />
|
||||
<?php echo PMA_generate_common_hidden_inputs($db, $table); ?>
|
||||
<?php echo $strAlterOrderBy; ?> :
|
||||
<select name="order_field" style="vertical-align: middle">
|
||||
<?php
|
||||
@@ -88,11 +84,7 @@ echo "\n";
|
||||
<div style="margin-bottom: 10px">
|
||||
<form method="post" action="tbl_rename.php3"
|
||||
onsubmit="return emptyFormElements(this, 'new_name')">
|
||||
<input type="hidden" name="server" value="<?php echo $server; ?>" />
|
||||
<input type="hidden" name="lang" value="<?php echo $lang; ?>" />
|
||||
<input type="hidden" name="convcharset" value="<?php echo $convcharset; ?>" />
|
||||
<input type="hidden" name="db" value="<?php echo htmlspecialchars($db); ?>" />
|
||||
<input type="hidden" name="table" value="<?php echo htmlspecialchars($table); ?>" />
|
||||
<?php echo PMA_generate_common_hidden_inputs($db, $table); ?>
|
||||
<input type="hidden" name="reload" value="1" />
|
||||
<?php echo $strRenameTable; ?> :
|
||||
<input type="text" size="20" name="new_name" value="<?php echo htmlspecialchars($table); ?>" class="textfield" onfocus="this.select()" />
|
||||
@@ -109,11 +101,7 @@ echo "\n";
|
||||
<td valign="top">
|
||||
<form method="post" action="tbl_move_copy.php3"
|
||||
onsubmit="return emptyFormElements(this, 'new_name')">
|
||||
<input type="hidden" name="server" value="<?php echo $server; ?>" />
|
||||
<input type="hidden" name="lang" value="<?php echo $lang; ?>" />
|
||||
<input type="hidden" name="convcharset" value="<?php echo $convcharset; ?>" />
|
||||
<input type="hidden" name="db" value="<?php echo htmlspecialchars($db); ?>" />
|
||||
<input type="hidden" name="table" value="<?php echo htmlspecialchars($table); ?>" />
|
||||
<?php echo PMA_generate_common_hidden_inputs($db, $table); ?>
|
||||
<input type="hidden" name="reload" value="1" />
|
||||
<input type="hidden" name="what" value="data" />
|
||||
<table border="0" cellspacing="0" cellpadding="0">
|
||||
@@ -128,7 +116,7 @@ echo "\n";
|
||||
<option value=""></option>
|
||||
<?php
|
||||
// The function used below is defined in "common.lib.php3"
|
||||
PMA_availableDatabases('main.php3?lang=' . $lang . '&server=' . $server);
|
||||
PMA_availableDatabases('main.php3?' . PMA_generate_common_url());
|
||||
for ($i = 0; $i < $num_dbs; $i++) {
|
||||
echo ' ';
|
||||
echo '<option value="' . str_replace('"', '"', $dblist[$i]) . '">' . htmlspecialchars($dblist[$i]) . '</option>';
|
||||
@@ -152,11 +140,7 @@ for ($i = 0; $i < $num_dbs; $i++) {
|
||||
<td valign="top">
|
||||
<form method="post" action="tbl_move_copy.php3"
|
||||
onsubmit="return emptyFormElements(this, 'new_name')">
|
||||
<input type="hidden" name="server" value="<?php echo $server; ?>" />
|
||||
<input type="hidden" name="lang" value="<?php echo $lang; ?>" />
|
||||
<input type="hidden" name="convcharset" value="<?php echo $convcharset; ?>" />
|
||||
<input type="hidden" name="db" value="<?php echo htmlspecialchars($db); ?>" />
|
||||
<input type="hidden" name="table" value="<?php echo htmlspecialchars($table); ?>" />
|
||||
<?php echo PMA_generate_common_hidden_inputs($db, $table); ?>
|
||||
<input type="hidden" name="reload" value="1" />
|
||||
<table border="0" cellspacing="0" cellpadding="0">
|
||||
<tr>
|
||||
|
@@ -58,10 +58,7 @@ if (PMA_MYSQL_INT_VERSION >= 32322) {
|
||||
<!-- Table comments -->
|
||||
<li>
|
||||
<form method="post" action="tbl_properties_options.php3">
|
||||
<input type="hidden" name="server" value="<?php echo $server; ?>" />
|
||||
<input type="hidden" name="lang" value="<?php echo $lang; ?>" />
|
||||
<input type="hidden" name="db" value="<?php echo htmlspecialchars($db); ?>" />
|
||||
<input type="hidden" name="table" value="<?php echo htmlspecialchars($table); ?>" />
|
||||
<?php echo PMA_generate_common_hidden_inputs($db, $table); ?>
|
||||
<?php echo $strTableComments; ?> :
|
||||
<input type="hidden" name="prev_comment" value="<?php echo urlencode($show_comment); ?>" />
|
||||
<input type="text" name="comment" maxlength="60" size="30" value="<?php echo htmlspecialchars($show_comment); ?>" class="textfield" style="vertical-align: middle" onfocus="this.select()" />
|
||||
@@ -108,10 +105,7 @@ if (PMA_MYSQL_INT_VERSION >= 32322) {
|
||||
?>
|
||||
<li>
|
||||
<form method="post" action="tbl_properties_options.php3">
|
||||
<input type="hidden" name="server" value="<?php echo $server; ?>" />
|
||||
<input type="hidden" name="lang" value="<?php echo $lang; ?>" />
|
||||
<input type="hidden" name="db" value="<?php echo htmlspecialchars($db); ?>" />
|
||||
<input type="hidden" name="table" value="<?php echo htmlspecialchars($table); ?>" />
|
||||
<?php echo PMA_generate_common_hidden_inputs($db, $table); ?>
|
||||
<?php echo $strTableType; ?> :
|
||||
<select name="tbl_type" style="vertical-align: middle">
|
||||
<option value="MYISAM"<?php if ($tbl_type == 'MYISAM') echo ' selected="selected"'; ?>>MyISAM</option>
|
||||
@@ -154,10 +148,7 @@ if (PMA_MYSQL_INT_VERSION >= 32322) {
|
||||
<tr>
|
||||
<td valign="top">
|
||||
<form method="post" action="tbl_properties_options.php3">
|
||||
<input type="hidden" name="server" value="<?php echo $server; ?>" />
|
||||
<input type="hidden" name="lang" value="<?php echo $lang; ?>" />
|
||||
<input type="hidden" name="db" value="<?php echo htmlspecialchars($db); ?>" />
|
||||
<input type="hidden" name="table" value="<?php echo htmlspecialchars($table); ?>" />
|
||||
<?php echo PMA_generate_common_hidden_inputs($db, $table); ?>
|
||||
|
||||
<table border="0" cellspacing="0" cellpadding="0">
|
||||
<tr>
|
||||
|
@@ -57,10 +57,7 @@ $fields_cnt = mysql_num_rows($fields_rs);
|
||||
<!-- TABLE INFORMATIONS -->
|
||||
|
||||
<form action="tbl_properties_structure.php3">
|
||||
<input type="hidden" name="lang" value="<?php echo $lang; ?>" />
|
||||
<input type="hidden" name="server" value="<?php echo $server; ?>" />
|
||||
<input type="hidden" name="db" value="<?php echo htmlspecialchars($db); ?>" />
|
||||
<input type="hidden" name="table" value="<?php echo htmlspecialchars($table); ?>" />
|
||||
<?php echo PMA_generate_common_hidden_inputs($db, $table); ?>
|
||||
|
||||
<table border="<?php echo $cfg['Border']; ?>">
|
||||
<tr>
|
||||
@@ -503,10 +500,7 @@ echo "\n";
|
||||
<li>
|
||||
<form method="post" action="tbl_addfield.php3"
|
||||
onsubmit="return checkFormElementInRange(this, 'num_fields', 1)">
|
||||
<input type="hidden" name="server" value="<?php echo $server; ?>" />
|
||||
<input type="hidden" name="lang" value="<?php echo $lang; ?>" />
|
||||
<input type="hidden" name="db" value="<?php echo htmlspecialchars($db); ?>" />
|
||||
<input type="hidden" name="table" value="<?php echo htmlspecialchars($table); ?>" />
|
||||
<?php echo PMA_generate_common_hidden_inputs($db, $table); ?>
|
||||
<?php echo $strAddNewField; ?> :
|
||||
<input type="text" name="num_fields" size="2" maxlength="2" value="1" class="textfield" style="vertical-align: middle" onfocus="this.select()" />
|
||||
<select name="after_field" style="vertical-align: middle">
|
||||
|
@@ -63,11 +63,7 @@ $auto_sel = ($cfg['TextareaAutoSelect'])
|
||||
<form method="post" action="read_dump.php3"<?php if ($is_upload) echo ' enctype="multipart/form-data"'; echo "\n"; ?>
|
||||
onsubmit="return checkSqlQuery(this)" name="sqlform">
|
||||
<input type="hidden" name="is_js_confirmed" value="0" />
|
||||
<input type="hidden" name="lang" value="<?php echo $lang; ?>" />
|
||||
<input type="hidden" name="convcharset" value="<?php echo $convcharset; ?>" />
|
||||
<input type="hidden" name="server" value="<?php echo $server; ?>" />
|
||||
<input type="hidden" name="db" value="<?php echo htmlspecialchars($db); ?>" />
|
||||
<input type="hidden" name="table" value="<?php echo htmlspecialchars($table); ?>" />
|
||||
<?php echo PMA_generate_common_hidden_inputs($db, $table); ?>
|
||||
<input type="hidden" name="pos" value="0" />
|
||||
<input type="hidden" name="goto" value="<?php echo $goto; ?>" />
|
||||
<input type="hidden" name="zero_rows" value="<?php echo $strSuccess; ?>" />
|
||||
|
@@ -214,10 +214,7 @@ if ($col_rs && mysql_num_rows($col_rs) > 0) {
|
||||
|
||||
?>
|
||||
<form method="post" action="tbl_relation.php3">
|
||||
<input type="hidden" name="lang" value="<?php echo $lang; ?>" />
|
||||
<input type="hidden" name="server" value="<?php echo $server; ?>" />
|
||||
<input type="hidden" name="db" value="<?php echo htmlspecialchars($db); ?>" />
|
||||
<input type="hidden" name="table" value="<?php echo htmlspecialchars($table); ?>" />
|
||||
<?php echo PMA_generate_common_hidden_inputs($db); ?>
|
||||
<input type="hidden" name="submit_rel" value="true" />
|
||||
|
||||
<table>
|
||||
@@ -289,10 +286,7 @@ if ($col_rs && mysql_num_rows($col_rs) > 0) {
|
||||
echo "\n";
|
||||
?>
|
||||
<form method="post" action="tbl_relation.php3">
|
||||
<input type="hidden" name="lang" value="<?php echo $lang; ?>" />
|
||||
<input type="hidden" name="server" value="<?php echo $server; ?>" />
|
||||
<input type="hidden" name="db" value="<?php echo htmlspecialchars($db); ?>" />
|
||||
<input type="hidden" name="table" value="<?php echo htmlspecialchars($table); ?>" />
|
||||
<?php echo PMA_generate_common_hidden_inputs($db); ?>
|
||||
<input type="hidden" name="submit_show" value="true" />
|
||||
|
||||
<p><?php echo $strChangeDisplay; ?></p>
|
||||
@@ -326,10 +320,7 @@ if ($col_rs && mysql_num_rows($col_rs) > 0) {
|
||||
echo "\n";
|
||||
?>
|
||||
<form method="post" action="tbl_relation.php3">
|
||||
<input type="hidden" name="lang" value="<?php echo $lang; ?>" />
|
||||
<input type="hidden" name="server" value="<?php echo $server; ?>" />
|
||||
<input type="hidden" name="db" value="<?php echo htmlspecialchars($db); ?>" />
|
||||
<input type="hidden" name="table" value="<?php echo htmlspecialchars($table); ?>" />
|
||||
<?php echo PMA_generate_common_hidden_inputs($db); ?>
|
||||
<input type="hidden" name="submit_comm" value="true" />
|
||||
|
||||
<table>
|
||||
|
@@ -14,12 +14,7 @@ require('./libraries/common.lib.php3');
|
||||
/**
|
||||
* Defines the url to return to in case of error in a sql statement
|
||||
*/
|
||||
$err_url = 'tbl_properties.php3'
|
||||
. '?lang=' . $lang
|
||||
. '&convcharset=' . $convcharset
|
||||
. '&server=' . $server
|
||||
. '&db=' . urlencode($db)
|
||||
. '&table=' . urlencode($table);
|
||||
$err_url = 'tbl_properties.php3?' . PMA_generate_common_url($db, $table);
|
||||
|
||||
|
||||
/**
|
||||
|
@@ -22,12 +22,8 @@ if (!isset($dontlimitchars)) {
|
||||
}
|
||||
$is_gotofile = FALSE;
|
||||
if (isset($after_insert) && $after_insert == 'new_insert') {
|
||||
$goto = 'tbl_change.php3'
|
||||
. '?lang=' . $lang
|
||||
. '&convcharset=' . $convcharset
|
||||
. '&server=' . $server
|
||||
. '&db=' . urlencode($db)
|
||||
. '&table=' . urlencode($table)
|
||||
$goto = 'tbl_change.php3?'
|
||||
. PMA_generate_common_url($db, $table)
|
||||
. '&goto=' . urlencode($goto)
|
||||
. '&pos=' . $pos
|
||||
. '&session_max_rows=' . $session_max_rows
|
||||
@@ -37,11 +33,7 @@ if (isset($after_insert) && $after_insert == 'new_insert') {
|
||||
. (empty($sql_query) ? '' : '&sql_query=' . urlencode($sql_query));
|
||||
} else if ($goto == 'sql.php3') {
|
||||
$goto = 'sql.php3?'
|
||||
. 'lang=' . $lang
|
||||
. '&convcharset=' . $convcharset
|
||||
. '&server=' . $server
|
||||
. '&db=' . urlencode($db)
|
||||
. '&table=' . urlencode($table)
|
||||
. PMA_generate_common_url($db, $table)
|
||||
. '&pos=' . $pos
|
||||
. '&session_max_rows=' . $session_max_rows
|
||||
. '&disp_direction=' . $disp_direction
|
||||
|
@@ -33,12 +33,7 @@ if (!isset($param) || $param[0] == '') {
|
||||
$goto = $cfg['DefaultTabTable'];
|
||||
}
|
||||
// Defines the url to return to in case of error in the next sql statement
|
||||
$err_url = $goto
|
||||
. '?lang=' . $lang
|
||||
. '&convcharset=' . $convcharset
|
||||
. '&server=' . $server
|
||||
. '&db=' . urlencode($db)
|
||||
. '&table=' . urlencode($table);
|
||||
$err_url = $goto . '?' . PMA_generate_common_url($db, $table);
|
||||
|
||||
// Gets the list and number of fields
|
||||
$local_query = 'SHOW FIELDS FROM ' . PMA_backquote($table) . ' FROM ' . PMA_backquote($db);
|
||||
@@ -74,11 +69,7 @@ if (!isset($param) || $param[0] == '') {
|
||||
$foreigners = ($cfgRelation['relwork'] ? PMA_getForeigners($db, $table) : FALSE);
|
||||
?>
|
||||
<form method="post" action="tbl_select.php3">
|
||||
<input type="hidden" name="server" value="<?php echo $server; ?>" />
|
||||
<input type="hidden" name="lang" value="<?php echo $lang; ?>" />
|
||||
<input type="hidden" name="convcharset" value="<?php echo $convcharset; ?>" />
|
||||
<input type="hidden" name="db" value="<?php echo htmlspecialchars($db); ?>" />
|
||||
<input type="hidden" name="table" value="<?php echo htmlspecialchars($table); ?>" />
|
||||
<?php echo PMA_generate_common_hidden_inputs($db, $table); ?>
|
||||
<input type="hidden" name="goto" value="<?php echo $goto; ?>" />
|
||||
<input type="hidden" name="back" value="tbl_select.php3" />
|
||||
|
||||
|
@@ -13,13 +13,7 @@ require('./libraries/common.lib.php3');
|
||||
/**
|
||||
* Defines the url to return to in case of error in a sql statement
|
||||
*/
|
||||
$err_url = 'user_details.php3'
|
||||
. '?lang=' . $lang
|
||||
. '&convcharset=' . $convcharset
|
||||
. '&server=' . $server
|
||||
. '&db=mysql'
|
||||
. '&table=user';
|
||||
|
||||
$err_url = 'user_details.php3?' . PMA_generate_common_url('mysql', 'user');
|
||||
|
||||
/**
|
||||
* Displays the table of grants for an user
|
||||
@@ -72,7 +66,7 @@ function PMA_tableGrants(&$host_db_result, $dbcheck = FALSE) {
|
||||
echo "\n";
|
||||
|
||||
// 2. Table body
|
||||
$url_query = 'lang=' . $lang . '&convcharset=' . $convcharset . '&server=' . $server . '&db=mysql&table=user';
|
||||
$url_query = PMA_generate_common_url('mysql', 'user');
|
||||
|
||||
while ($row = (is_array($host_db_result) ? $host_db_result : PMA_mysql_fetch_array($host_db_result))) {
|
||||
$local_query = 'SHOW GRANTS FOR \'' . $row['User'] . '\'@\'' . $row['Host'] . '\'';
|
||||
@@ -346,7 +340,7 @@ function PMA_normalOperations()
|
||||
|
||||
<li>
|
||||
<div style="margin-bottom: 10px">
|
||||
<a href="user_details.php3?lang=<?php echo $lang; ?>&convcharset=<?php echo $convcharset; ?>&server=<?php echo $server; ?>&db=mysql&table=user&mode=reload">
|
||||
<a href="user_details.php3?<?php echo PMA_generate_common_url('mysql', 'user'); ?>&mode=reload">
|
||||
<?php echo $GLOBALS['strReloadMySQL']; ?></a>
|
||||
<?php echo PMA_showMySQLDocu('MySQL_Database_Administration.', 'FLUSH') . "\n"; ?>
|
||||
</div>
|
||||
@@ -371,9 +365,7 @@ function PMA_normalOperations()
|
||||
} // end if
|
||||
?>
|
||||
</select>
|
||||
<input type="hidden" name="lang" value="<?php echo $lang; ?>" />
|
||||
<input type="hidden" name="convcharset" value="<?php echo $convcharset; ?>" />
|
||||
<input type="hidden" name="server" value="<?php echo $server; ?>" />
|
||||
<?php echo PMA_generate_common_hidden_inputs(); ?>
|
||||
<input type="hidden" name="check" value="1" />
|
||||
<input type="submit" value="<?php echo $GLOBALS['strGo']; ?>" />
|
||||
</td>
|
||||
@@ -443,9 +435,7 @@ function PMA_normalOperations()
|
||||
echo "\n";
|
||||
PMA_tablePrivileges('addUserForm');
|
||||
?>
|
||||
<input type="hidden" name="lang" value="<?php echo $lang; ?>" />
|
||||
<input type="hidden" name="convcharset" value="<?php echo $convcharset; ?>" />
|
||||
<input type="hidden" name="server" value="<?php echo $server; ?>" />
|
||||
<?php echo PMA_generate_common_hidden_inputs(); ?>
|
||||
<input type="submit" name="submit_addUser" value="<?php echo $GLOBALS['strGo']; ?>" />
|
||||
</form>
|
||||
</li>
|
||||
@@ -485,16 +475,14 @@ function PMA_grantOperations($grants)
|
||||
|
||||
<li>
|
||||
<div style="margin-bottom: 10px">
|
||||
<a href="user_details.php3?lang=<?php echo $lang; ?>&convcharset=<?php echo $convcharset; ?>&server=<?php echo $server; ?>&db=mysql&table=user">
|
||||
<a href="user_details.php3?<?php echo PMA_generate_common_url('mysql', 'user'); ?>">
|
||||
<?php echo $GLOBALS['strBack']; ?></a>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
<li>
|
||||
<form action="user_details.php3" method="post" name="userGrants">
|
||||
<input type="hidden" name="lang" value="<?php echo $lang; ?>" />
|
||||
<input type="hidden" name="convcharset" value="<?php echo $convcharset; ?>" />
|
||||
<input type="hidden" name="server" value="<?php echo $server; ?>" />
|
||||
<?php echo PMA_generate_common_hidden_inputs(); ?>
|
||||
<input type="hidden" name="grants" value="1" />
|
||||
<input type="hidden" name="host" value="<?php echo str_replace('"', '"', $host); ?>" />
|
||||
<input type="hidden" name="pma_user" value="<?php echo str_replace('"', '"', $pma_user); ?>" />
|
||||
@@ -686,7 +674,7 @@ function PMA_editOperations($host, $user)
|
||||
|
||||
<li>
|
||||
<div style="margin-bottom: 10px">
|
||||
<a href="user_details.php3?lang=<?php echo $lang; ?>&convcharset=<?php echo $convcharset; ?>&server=<?php echo $server; ?>&db=mysql&table=user">
|
||||
<a href="user_details.php3?<?php echo PMA_generate_common_url('mysql', 'user'); ?>">
|
||||
<?php echo $GLOBALS['strBack']; ?></a>
|
||||
</div>
|
||||
</li>
|
||||
@@ -751,9 +739,7 @@ function PMA_editOperations($host, $user)
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<input type="hidden" name="lang" value="<?php echo $lang; ?>" />
|
||||
<input type="hidden" name="convcharset" value="<?php echo $convcharset; ?>" />
|
||||
<input type="hidden" name="server" value="<?php echo $server; ?>" />
|
||||
<?php echo PMA_generate_common_hidden_inputs(); ?>
|
||||
<input type="hidden" name="host" value="<?php echo str_replace('"', '"', $host); ?>" />
|
||||
<input type="hidden" name="pma_user" value="<?php echo str_replace('"', '"', $user); ?>" />
|
||||
<input type="submit" name="submit_updProfile" value="<?php echo $GLOBALS['strGo']; ?>" />
|
||||
@@ -767,9 +753,7 @@ function PMA_editOperations($host, $user)
|
||||
PMA_tablePrivileges('privForm', $row);
|
||||
echo "\n";
|
||||
?>
|
||||
<input type="hidden" name="lang" value="<?php echo $lang; ?>" />
|
||||
<input type="hidden" name="convcharset" value="<?php echo $convcharset; ?>" />
|
||||
<input type="hidden" name="server" value="<?php echo $server; ?>" />
|
||||
<?php echo PMA_generate_common_hidden_inputs(); ?>
|
||||
<input type="hidden" name="host" value="<?php echo str_replace('"', '"', $host); ?>" />
|
||||
<input type="hidden" name="pma_user" value="<?php echo str_replace('"', '"', $user); ?>" />
|
||||
<input type="submit" name="submit_chgPriv" value="<?php echo $GLOBALS['strGo']; ?>" />
|
||||
@@ -879,17 +863,17 @@ function PMA_tableUsers($host = FALSE, $user = FALSE)
|
||||
$strPriv = '<span style="color: #002E80">' . $GLOBALS['strNoPrivileges'] . '</span>';
|
||||
}
|
||||
|
||||
$query = 'lang=' . $lang . '&server=' . $server . '&db=mysql&table=user&convcharset=' . $convcharset;
|
||||
$query = PMA_generate_common_url('mysql', 'user');
|
||||
if (!$user) {
|
||||
$edit_url = 'user_details.php3'
|
||||
. '?lang=' . $lang . '&convcharset=' . $convcharset . '&server=' . $server
|
||||
$edit_url = 'user_details.php3?'
|
||||
. PMA_generate_common_url()
|
||||
. '&edit=1&host=' . urlencode($row['Host']) . '&pma_user=' . urlencode($row['User']);
|
||||
}
|
||||
$delete_url = 'user_details.php3'
|
||||
. '?' . $query
|
||||
$delete_url = 'user_details.php3?'
|
||||
. $query
|
||||
. '&delete=1&confirm=1&delete_host=' . urlencode($row['Host']) . '&delete_user=' . urlencode($row['User']);
|
||||
$check_url = 'user_details.php3'
|
||||
. '?lang=' . $lang . '&convcharset=' . $convcharset . '&server=' . $server
|
||||
$check_url = 'user_details.php3?'
|
||||
. PMA_generate_common_url()
|
||||
. '&grants=1&host=' . urlencode($row['Host']) . '&pma_user=' . urlencode($row['User']);
|
||||
?>
|
||||
|
||||
@@ -972,11 +956,7 @@ function PMA_confirm($the_host, $the_user) {
|
||||
echo 'DELETE FROM mysql.user WHERE Host = \'' . $the_host . '\' AND User = \'' . $the_user . '\'' . '<br />' . "\n";
|
||||
?>
|
||||
<form action="user_details.php3" method="post">
|
||||
<input type="hidden" name="lang" value="<?php echo $lang; ?>" />
|
||||
<input type="hidden" name="convcharset" value="<?php echo $convcharset; ?>" />
|
||||
<input type="hidden" name="server" value="<?php echo $server; ?>" />
|
||||
<input type="hidden" name="db" value="mysql" />
|
||||
<input type="hidden" name="table" value="user" />
|
||||
<?php echo PMA_generate_common_hidden_inputs('mysql', 'user'); ?>
|
||||
<input type="hidden" name="delete" value="<?php echo(isset($GLOBALS['delete']) ? '1' : '0'); ?>" />
|
||||
<input type="hidden" name="delete_host" value="<?php echo str_replace('"', '"', $the_host); ?>" />
|
||||
<input type="hidden" name="delete_user" value="<?php echo str_replace('"', '"', $the_user); ?>" />
|
||||
@@ -1501,7 +1481,7 @@ else if (isset($check) && $check) {
|
||||
?>
|
||||
<ul>
|
||||
<li>
|
||||
<a href="user_details.php3?lang=<?php echo $lang;?>&convcharset=<?php echo $convcharset; ?>&server=<?php echo $server; ?>&db=mysql&table=user">
|
||||
<a href="user_details.php3?<?php echo PMA_generate_common_url('mysql', 'user'); ?>">
|
||||
<?php echo $strBack; ?></a>
|
||||
</li>
|
||||
</ul>
|
||||
|
@@ -50,9 +50,7 @@ if (isset($nopass)) {
|
||||
}
|
||||
|
||||
// Defines the url to return to in case of error in the sql statement
|
||||
$common_url_query = 'lang=' . $lang
|
||||
. '&convcharset=' . $convcharset
|
||||
. '&server=' . $server;
|
||||
$common_url_query = PMA_generate_common_url();
|
||||
|
||||
$err_url = 'user_password.php3?' . $common_url_query;
|
||||
|
||||
@@ -107,8 +105,7 @@ $chg_evt_handler = (PMA_USR_BROWSER_AGENT == 'IE' && PMA_USR_BROWSER_VER >= 5)
|
||||
// Displays the form
|
||||
?>
|
||||
<form method="post" action="./user_password.php3" name="chgPassword" onsubmit="return checkPassword(this)">
|
||||
<input type="hidden" name="lang" value="<?php echo $lang; ?>" />
|
||||
<input type="hidden" name="server" value="<?php echo $server; ?>" />
|
||||
<?php echo PMA_generate_common_hidden_inputs(); ?>
|
||||
<table border="0">
|
||||
<tr>
|
||||
<td colspan="2">
|
||||
|
Reference in New Issue
Block a user