operations

This commit is contained in:
Marc Delisle
2002-04-28 12:03:04 +00:00
parent 6d86bd193e
commit 173a482610
48 changed files with 287 additions and 222 deletions

View File

@@ -10,8 +10,9 @@ $Source$
start the split start the split
* tbl_properties.php3, new tbl_properties_export.php3, * tbl_properties.php3, new tbl_properties_export.php3,
tbl_properties_links.php3, lang/*.php3: export is splitted tbl_properties_links.php3, lang/*.php3: export is splitted
* new tbl_properties_table_info, to be able to display links * new tbl_properties_table_info.php3, to be able to display links
on the export page on the export page
* new tbl_properties_operations.php3
2002-04-28 Alexander M. Turek <rabus@users.sourceforge.net> 2002-04-28 Alexander M. Turek <rabus@users.sourceforge.net>
* header.inc.php3, lines 162-170: Improved patch #548696. * header.inc.php3, lines 162-170: Improved patch #548696.

View File

@@ -356,4 +356,5 @@ $strZip = '"zipped" "
$strCardinality = 'Cardinality'; $strCardinality = 'Cardinality';
$strLinksTo = 'Links to'; //to translate $strLinksTo = 'Links to'; //to translate
$strExport = 'Export'; //to translate $strExport = 'Export'; //to translate
$strOperations = 'Operations'; //to translate
?> ?>

View File

@@ -354,4 +354,5 @@ $strZip = '"compactado com zip"';
// To translate // To translate
$strLinksTo = 'Links to'; //to translate $strLinksTo = 'Links to'; //to translate
$strExport = 'Export'; //to translate $strExport = 'Export'; //to translate
$strOperations = 'Operations'; //to translate
?> ?>

View File

@@ -355,4 +355,5 @@ $strZip = '"zip-
// To translate // To translate
$strLinksTo = 'Links to'; //to translate $strLinksTo = 'Links to'; //to translate
$strExport = 'Export'; //to translate $strExport = 'Export'; //to translate
$strOperations = 'Operations'; //to translate
?> ?>

View File

@@ -355,4 +355,5 @@ $strZip = '"zip-
// To translate // To translate
$strLinksTo = 'Links to'; //to translate $strLinksTo = 'Links to'; //to translate
$strExport = 'Export'; //to translate $strExport = 'Export'; //to translate
$strOperations = 'Operations'; //to translate
?> ?>

View File

@@ -350,4 +350,5 @@ $strZip = '"comprimit amb zip"';
// To translate // To translate
$strLinksTo = 'Links to'; //to translate $strLinksTo = 'Links to'; //to translate
$strExport = 'Export'; //to translate $strExport = 'Export'; //to translate
$strOperations = 'Operations'; //to translate
?> ?>

View File

@@ -352,4 +352,5 @@ $strZip = '"zipped"';
$strLinksTo = 'Links to'; //to translate $strLinksTo = 'Links to'; //to translate
$strExport = 'Export'; //to translate $strExport = 'Export'; //to translate
$strOperations = 'Operations'; //to translate
?> ?>

View File

@@ -348,4 +348,5 @@ $strYes = '
$strZip = '"zipped"'; $strZip = '"zipped"';
$strLinksTo = 'Links to'; //to translate $strLinksTo = 'Links to'; //to translate
$strExport = 'Export'; //to translate $strExport = 'Export'; //to translate
$strOperations = 'Operations'; //to translate
?> ?>

View File

@@ -355,4 +355,5 @@ $strZip = '"zip-ano"';
// To translate // To translate
$strLinksTo = 'Links to'; $strLinksTo = 'Links to';
$strExport = 'Export'; //to translate $strExport = 'Export'; //to translate
$strOperations = 'Operations'; //to translate
?> ?>

View File

@@ -355,4 +355,5 @@ $strZip = '"zip-ano"';
// To translate // To translate
$strLinksTo = 'Links to'; $strLinksTo = 'Links to';
$strExport = 'Export'; //to translate $strExport = 'Export'; //to translate
$strOperations = 'Operations'; //to translate
?> ?>

View File

@@ -351,4 +351,5 @@ $strZip = '"zazipov
// To translate // To translate
$strLinksTo = 'Links to'; //to translate $strLinksTo = 'Links to'; //to translate
$strExport = 'Export'; //to translate $strExport = 'Export'; //to translate
$strOperations = 'Operations'; //to translate
?> ?>

View File

@@ -350,4 +350,5 @@ $strZip = '"zazipov
// To translate // To translate
$strLinksTo = 'Links to'; //to translate $strLinksTo = 'Links to'; //to translate
$strExport = 'Export'; //to translate $strExport = 'Export'; //to translate
$strOperations = 'Operations'; //to translate
?> ?>

View File

@@ -349,4 +349,5 @@ $strZip = '"zipped"';
$strLinksTo = 'Links to'; //to translate $strLinksTo = 'Links to'; //to translate
$strExport = 'Export'; //to translate $strExport = 'Export'; //to translate
$strOperations = 'Operations'; //to translate
?> ?>

View File

@@ -347,4 +347,5 @@ $strYes = 'Ja';
$strZip = '"Gezipt"'; $strZip = '"Gezipt"';
$strLinksTo = 'Links to'; //to translate $strLinksTo = 'Links to'; //to translate
$strExport = 'Export'; //to translate $strExport = 'Export'; //to translate
$strOperations = 'Operations'; //to translate
?> ?>

View File

@@ -349,4 +349,5 @@ $strYes = 'Yes';
$strZip = '"zipped"'; $strZip = '"zipped"';
$strOperations = 'Operations'; //to translate
?> ?>

View File

@@ -350,4 +350,5 @@ $strZip = '"zipitud"';
// To translate // To translate
$strLinksTo = 'Links to'; //to translate $strLinksTo = 'Links to'; //to translate
$strExport = 'Export'; //to translate $strExport = 'Export'; //to translate
$strOperations = 'Operations'; //to translate
?> ?>

View File

@@ -354,4 +354,5 @@ $strZip = '"zip-pakattu"';
// To translate // To translate
$strLinksTo = 'Links to'; //to translate $strLinksTo = 'Links to'; //to translate
$strExport = 'Export'; //to translate $strExport = 'Export'; //to translate
$strOperations = 'Operations'; //to translate
?> ?>

View File

@@ -349,4 +349,5 @@ $strYes = 'Oui';
$strZip = '"zipp<70>"'; $strZip = '"zipp<70>"';
$strOperations = 'Operations'; //to translate
?> ?>

View File

@@ -354,4 +354,5 @@ $strZip = 'comprimido no formato "zipped"';
// To translate // To translate
$strLinksTo = 'Links to'; //to translate $strLinksTo = 'Links to'; //to translate
$strExport = 'Export'; //to translate $strExport = 'Export'; //to translate
$strOperations = 'Operations'; //to translate
?> ?>

View File

@@ -359,4 +359,5 @@ $strPrimaryKeyName = 'The name of the primary key must be... PRIMARY!';
$strPrimaryKeyWarning = '("PRIMARY" <b>must</b> be the name of and <b>only of</b> a primary key!)'; $strPrimaryKeyWarning = '("PRIMARY" <b>must</b> be the name of and <b>only of</b> a primary key!)';
$strLinksTo = 'Links to'; //to translate $strLinksTo = 'Links to'; //to translate
$strExport = 'Export'; //to translate $strExport = 'Export'; //to translate
$strOperations = 'Operations'; //to translate
?> ?>

View File

@@ -350,4 +350,5 @@ $strZip = '"Zip komprimiert"';
// To translate // To translate
$strExport = 'Export'; //to translate $strExport = 'Export'; //to translate
$strOperations = 'Operations'; //to translate
?> ?>

View File

@@ -351,4 +351,5 @@ $strZip = '
// To translate // To translate
$strLinksTo = 'Links to'; //to translate $strLinksTo = 'Links to'; //to translate
$strExport = 'Export'; //to translate $strExport = 'Export'; //to translate
$strOperations = 'Operations'; //to translate
?> ?>

View File

@@ -350,4 +350,5 @@ $strZip = '"Zipped"';
$strLinksTo = 'Links to'; //to translate $strLinksTo = 'Links to'; //to translate
$strExport = 'Export'; //to translate $strExport = 'Export'; //to translate
$strOperations = 'Operations'; //to translate
?> ?>

View File

@@ -352,4 +352,5 @@ $strZip = '"zippel t
$strLinksTo = 'Links to'; //to translate $strLinksTo = 'Links to'; //to translate
$strExport = 'Export'; //to translate $strExport = 'Export'; //to translate
$strOperations = 'Operations'; //to translate
?> ?>

View File

@@ -349,4 +349,5 @@ $strZip = '"Dikompress dengan Zip"';
$strLinksTo = 'Links to'; //to translate $strLinksTo = 'Links to'; //to translate
$strExport = 'Export'; //to translate $strExport = 'Export'; //to translate
$strOperations = 'Operations'; //to translate
?> ?>

View File

@@ -357,4 +357,5 @@ $strZip = '"compresso con zip"';
// To translate // To translate
$strExport = 'Export'; //to translate $strExport = 'Export'; //to translate
$strOperations = 'Operations'; //to translate
?> ?>

View File

@@ -359,4 +359,5 @@ $strXkana = '
// To translate // To translate
$strLinksTo = 'Links to'; //to translate $strLinksTo = 'Links to'; //to translate
$strExport = 'Export'; //to translate $strExport = 'Export'; //to translate
$strOperations = 'Operations'; //to translate
?> ?>

View File

@@ -359,4 +359,5 @@ $strXkana = '
// To translate // To translate
$strLinksTo = 'Links to'; //to translate $strLinksTo = 'Links to'; //to translate
$strExport = 'Export'; //to translate $strExport = 'Export'; //to translate
$strOperations = 'Operations'; //to translate
?> ?>

View File

@@ -351,4 +351,5 @@ $strZip = 'zip
// To translate // To translate
$strLinksTo = 'Links to'; //to translate $strLinksTo = 'Links to'; //to translate
$strExport = 'Export'; //to translate $strExport = 'Export'; //to translate
$strOperations = 'Operations'; //to translate
?> ?>

View File

@@ -354,4 +354,5 @@ $strZip = 'arhiv
// To translate // To translate
$strLinksTo = 'Links to'; //to translate $strLinksTo = 'Links to'; //to translate
$strExport = 'Export'; //to translate $strExport = 'Export'; //to translate
$strOperations = 'Operations'; //to translate
?> ?>

View File

@@ -350,4 +350,5 @@ $strZip = '"zip"';
$strReferentialIntegrity = 'Check referential integrity:'; //to translate $strReferentialIntegrity = 'Check referential integrity:'; //to translate
$strLinksTo = 'Links to'; //to translate $strLinksTo = 'Links to'; //to translate
$strExport = 'Export'; //to translate $strExport = 'Export'; //to translate
$strOperations = 'Operations'; //to translate
?> ?>

View File

@@ -354,4 +354,5 @@ $strZip = 'Komprimert (zip)';
// To translate // To translate
$strLinksTo = 'Links to'; //to translate $strLinksTo = 'Links to'; //to translate
$strExport = 'Export'; //to translate $strExport = 'Export'; //to translate
$strOperations = 'Operations'; //to translate
?> ?>

View File

@@ -350,4 +350,5 @@ $strZip = '".zip"';
// To translate // To translate
$strLinksTo = 'Links to'; //to translate $strLinksTo = 'Links to'; //to translate
$strExport = 'Export'; //to translate $strExport = 'Export'; //to translate
$strOperations = 'Operations'; //to translate
?> ?>

View File

@@ -357,4 +357,5 @@ $strZip = '"Compress
// To translate // To translate
$strLinksTo = 'Links to'; //to translate $strLinksTo = 'Links to'; //to translate
$strExport = 'Export'; //to translate $strExport = 'Export'; //to translate
$strOperations = 'Operations'; //to translate
?> ?>

View File

@@ -350,4 +350,5 @@ $strZip = '"arhivat"';
// To translate // To translate
$strLinksTo = 'Links to'; //to translate $strLinksTo = 'Links to'; //to translate
$strExport = 'Export'; //to translate $strExport = 'Export'; //to translate
$strOperations = 'Operations'; //to translate
?> ?>

View File

@@ -355,4 +355,5 @@ $strZip = '
// To translate // To translate
$strLinksTo = 'Links to'; //to translate $strLinksTo = 'Links to'; //to translate
$strExport = 'Export'; //to translate $strExport = 'Export'; //to translate
$strOperations = 'Operations'; //to translate
?> ?>

View File

@@ -355,4 +355,5 @@ $strZip = '
// To translate // To translate
$strLinksTo = 'Links to'; //to translate $strLinksTo = 'Links to'; //to translate
$strExport = 'Export'; //to translate $strExport = 'Export'; //to translate
$strOperations = 'Operations'; //to translate
?> ?>

View File

@@ -356,4 +356,5 @@ $strZip = '"zip-ovano"';
// To translate // To translate
$strLinksTo = 'Links to'; //to translate $strLinksTo = 'Links to'; //to translate
$strExport = 'Export'; //to translate $strExport = 'Export'; //to translate
$strOperations = 'Operations'; //to translate
?> ?>

View File

@@ -353,4 +353,5 @@ $strZip = '"zo zipovan
// To translate // To translate
$strLinksTo = 'Links to'; //to translate $strLinksTo = 'Links to'; //to translate
$strExport = 'Export'; //to translate $strExport = 'Export'; //to translate
$strOperations = 'Operations'; //to translate
?> ?>

View File

@@ -353,4 +353,5 @@ $strZip = '"zozipovan
// To translate // To translate
$strLinksTo = 'Links to'; //to translate $strLinksTo = 'Links to'; //to translate
$strExport = 'Export'; //to translate $strExport = 'Export'; //to translate
$strOperations = 'Operations'; //to translate
?> ?>

View File

@@ -348,4 +348,5 @@ $strZip = '"comprimido con zip"';
// To translate // To translate
$strLinksTo = 'Links to'; //to translate $strLinksTo = 'Links to'; //to translate
$strExport = 'Export'; //to translate $strExport = 'Export'; //to translate
$strOperations = 'Operations'; //to translate
?> ?>

View File

@@ -350,4 +350,5 @@ $strZip = '"zippad"';
// To translate // To translate
$strLinksTo = 'Links to'; //to translate $strLinksTo = 'Links to'; //to translate
$strExport = 'Export'; //to translate $strExport = 'Export'; //to translate
$strOperations = 'Operations'; //to translate
?> ?>

View File

@@ -356,4 +356,5 @@ $strPrimaryKeyWarning = '("PRIMARY" <b>must</b> be the name of and <b>only of</b
$strReferentialIntegrity = 'Check referential integrity:'; //to translate $strReferentialIntegrity = 'Check referential integrity:'; //to translate
$strLinksTo = 'Links to'; //to translate $strLinksTo = 'Links to'; //to translate
$strExport = 'Export'; //to translate $strExport = 'Export'; //to translate
$strOperations = 'Operations'; //to translate
?> ?>

View File

@@ -350,4 +350,5 @@ $strZip = '"ziplenmi
// To translate // To translate
$strLinksTo = 'Links to'; //to translate $strLinksTo = 'Links to'; //to translate
$strExport = 'Export'; //to translate $strExport = 'Export'; //to translate
$strOperations = 'Operations'; //to translate
?> ?>

View File

@@ -350,4 +350,5 @@ $strZip = '
// To translate // To translate
$strLinksTo = 'Links to'; //to translate $strLinksTo = 'Links to'; //to translate
$strExport = 'Export'; //to translate $strExport = 'Export'; //to translate
$strOperations = 'Operations'; //to translate
?> ?>

View File

@@ -664,194 +664,9 @@ if ($is_upload) {
<?php <?php
} }
echo "\n"; echo "\n";
?>
<!-- Change table name -->
<li>
<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="db" value="<?php echo $db; ?>" />
<input type="hidden" name="table" value="<?php echo $table; ?>" />
<input type="hidden" name="reload" value="1" />
<?php echo $strRenameTable; ?>&nbsp;:
<input type="text" size="20" name="new_name" value="<?php echo htmlspecialchars($table); ?>" class="textfield" onfocus="this.select()" />&nbsp;
<input type="submit" value="<?php echo $strGo; ?>" />
</form>
</div>
</li>
<!-- Move and copy table -->
<li style="vertical-align: top">
<div style="margin-bottom: 10px">
<table border="0" cellspacing="0" cellpadding="0" style="vertical-align: top">
<tr>
<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="db" value="<?php echo $db; ?>" />
<input type="hidden" name="table" value="<?php echo $table; ?>" />
<input type="hidden" name="reload" value="1" />
<input type="hidden" name="what" value="data" />
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td nowrap="nowrap">
<?php echo $strMoveTable . "\n"; ?>
</td>
</tr>
<tr>
<td>
<select name="target_db">
<option value=""></option>
<?php
// The function used below is defined in "common.lib.php3"
PMA_availableDatabases('main.php3?lang=' . $lang . '&amp;server=' . $server);
for ($i = 0; $i < $num_dbs; $i++) {
echo ' ';
echo '<option value="' . str_replace('"', '&quot;', $dblist[$i]) . '">' . htmlspecialchars($dblist[$i]) . '</option>';
echo "\n";
} // end for
?>
</select>
&nbsp;<b>.</b>&nbsp;
<input type="text" size="20" name="new_name" value="<?php echo $table; ?>" class="textfield" onfocus="this.select()" />
</td>
</tr>
<tr>
<td align="<?php echo $cell_align_right; ?>" valign="top">
<input type="submit" name="submit_move" value="<?php echo $strGo; ?>" />
</td>
</tr>
</table>
</form>
</td>
<td width="25">&nbsp;</td>
<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="db" value="<?php echo $db; ?>" />
<input type="hidden" name="table" value="<?php echo $table; ?>" />
<input type="hidden" name="reload" value="1" />
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td colspan="2" nowrap="nowrap">
<?php echo $strCopyTable . "\n"; ?>
</td>
</tr>
<tr>
<td colspan="2">
<select name="target_db">
<?php
for ($i = 0; $i < $num_dbs; $i++) {
echo ' ';
echo '<option value="' . str_replace('"', '&quot;', $dblist[$i]) . '"';
if ($dblist[$i] == $db) {
echo ' selected="selected"';
}
echo '>' . htmlspecialchars($dblist[$i]) . '</option>';
echo "\n";
} // end for
?>
</select>
&nbsp;<b>.</b>&nbsp;
<input type="text" size="20" name="new_name" class="textfield" onfocus="this.select()" />
</td>
</tr>
<tr>
<td nowrap="nowrap">
<input type="radio" name="what" value="structure" id="radio_copy_structure" checked="checked" />
<label for="radio_copy_structure"><?php echo $strStrucOnly; ?></label>&nbsp;&nbsp;<br />
<input type="radio" name="what" value="data" id="radio_copy_data" />
<label for="radio_copy_data"><?php echo $strStrucData; ?></label>&nbsp;&nbsp;
</td>
<td align="<?php echo $cell_align_right; ?>" valign="top">
<input type="submit" name="submit_copy" value="<?php echo $strGo; ?>" />
</td>
</tr>
</table>
</form>
</td>
</tr>
</table>
</div>
</li>
<?php
if (PMA_MYSQL_INT_VERSION >= 32322) { if (PMA_MYSQL_INT_VERSION >= 32322) {
if ($tbl_type == 'MYISAM' or $tbl_type == 'BDB') { ?>
?>
<!-- Table maintenance -->
<li style="vertical-align: top">
<div style="margin-bottom: 10px">
<table border="0" cellspacing="0" cellpadding="0" style="vertical-align: top">
<tr>
<td><?php echo $strTableMaintenance; ?>&nbsp;:&nbsp;</td>
<?php
echo "\n";
if ($tbl_type == 'MYISAM') {
?>
<td>
<a href="sql.php3?<?php echo $url_query; ?>&amp;sql_query=<?php echo urlencode('CHECK TABLE ' . PMA_backquote($table)); ?>">
<?php echo $strCheckTable; ?></a>&nbsp;
<?php echo PMA_showDocuShort('C/H/CHECK_TABLE.html') . "\n"; ?>
</td>
<td>&nbsp;-&nbsp;</td>
<?php
}
echo "\n";
if ($tbl_type == 'MYISAM' || $tbl_type == 'BDB') {
?>
<td>
<a href="sql.php3?<?php echo $url_query; ?>&amp;sql_query=<?php echo urlencode('ANALYZE TABLE ' . PMA_backquote($table)); ?>">
<?php echo $strAnalyzeTable; ?></a>&nbsp;
<?php echo PMA_showDocuShort('A/N/ANALYZE_TABLE.html') . "\n";?>
</td>
<?php
}
echo "\n";
?>
</tr>
<tr>
<td>&nbsp;</td>
<?php
echo "\n";
if ($tbl_type == 'MYISAM') {
?>
<td>
<a href="sql.php3?<?php echo $url_query; ?>&amp;sql_query=<?php echo urlencode('REPAIR TABLE ' . PMA_backquote($table)); ?>">
<?php echo $strRepairTable; ?></a>&nbsp;
<?php echo PMA_showDocuShort('R/E/REPAIR_TABLE.html') . "\n"; ?>
</td>
<td>&nbsp;-&nbsp;</td>
<?php
}
echo "\n";
if ($tbl_type == 'MYISAM' || $tbl_type == 'BDB') {
?>
<td>
<a href="sql.php3?<?php echo $url_query; ?>&amp;sql_query=<?php echo urlencode('OPTIMIZE TABLE ' . PMA_backquote($table)); ?>">
<?php echo $strOptimizeTable; ?></a>&nbsp;
<?php echo PMA_showDocuShort('O/P/OPTIMIZE_TABLE.html') . "\n"; ?>
</td>
<?php
}
echo "\n";
?>
</tr>
</table><br />
</div>
</li>
<?php
} // end MYISAM or BDB case
echo "\n";
?>
<!-- Table comments --> <!-- Table comments -->
<li> <li>
<form method="post" action="tbl_properties.php3"> <form method="post" action="tbl_properties.php3">
@@ -927,24 +742,6 @@ if (PMA_MYSQL_INT_VERSION >= 32322) {
echo "\n"; echo "\n";
} // end MySQL >= 3.23.22 } // end MySQL >= 3.23.22
// loic1: "OPTIMIZE" statement is available for MyISAM and BDB tables only and
// MyISAM/BDB tables exists since MySQL 3.23.06/3.23.34
else if (PMA_MYSQL_INT_VERSION >= 32306
&& ($tbl_type == 'MYISAM' or $tbl_type == 'BDB')) {
?>
<!-- Table maintenance -->
<li style="vertical-align: top">
<div style="margin-bottom: 10px">
<?php echo $strTableMaintenance; ?>&nbsp;:&nbsp;
<a href="sql.php3?<?php echo $url_query; ?>&amp;sql_query=<?php echo urlencode('OPTIMIZE TABLE ' . PMA_backquote($table)); ?>">
<?php echo $strOptimizeTable; ?></a>&nbsp;
<?php echo PMA_showDocuShort('O/P/OPTIMIZE_TABLE.html') . "\n"; ?>
</div>
</li>
<?php
echo "\n";
} // end 3.23.06 < MySQL < 3.23.22
// Referential integrity check // Referential integrity check
if (!empty($cfg['Server']['relation'])) { if (!empty($cfg['Server']['relation'])) {
@@ -990,20 +787,6 @@ if (!empty($cfg['Server']['relation'])) {
} // end if (!empty($cfg['Server']['relation'])) } // end if (!empty($cfg['Server']['relation']))
?> ?>
<!-- Flushes the table -->
<li>
<a href="sql.php3?<?php echo $url_query; ?>&amp;sql_query=<?php echo urlencode('FLUSH TABLE ' . PMA_backquote($table)); ?>&amp;zero_rows=<?php echo urlencode(sprintf($strTableHasBeenFlushed, htmlspecialchars($table))); if ($cfg['ShowTooltip']) echo '&amp;reload=1'; ?>">
<?php echo $strFlushTable; ?></a>
<br /><br />
</li>
<!-- Deletes the table -->
<li>
<a href="sql.php3?<?php echo ereg_replace('tbl_properties.php3$', 'db_details.php3', $url_query); ?>&amp;back=tbl_properties.php3&amp;reload=1&amp;sql_query=<?php echo urlencode('DROP TABLE ' . PMA_backquote($table)); ?>&amp;zero_rows=<?php echo urlencode(sprintf($strTableHasBeenDropped, htmlspecialchars($table))); ?>"
onclick="return confirmLink(this, 'DROP TABLE <?php echo PMA_jsFormat($table); ?>')">
<?php echo $strDropTable; ?></a>
</li>
</ul> </ul>
<?php <?php

View File

@@ -5,14 +5,14 @@
/** /**
* Prepares links * Prepares links
*/ */
$lnk3 = '<a href="tbl_properties_export.php3?' . $url_query . '">'; $lnk3 = '<a href="tbl_properties_export.php3?' . $url_query . '">';
$lnk5 = '<a href="tbl_properties_operations.php3?' . $url_query . '">';
if ($num_rows > 0) { if ($num_rows > 0) {
$lnk1 = '<a href="sql.php3?' . $url_query $lnk1 = '<a href="sql.php3?' . $url_query
. '&amp;sql_query=' . urlencode('SELECT * FROM ' . PMA_backquote($table)) . '&amp;sql_query=' . urlencode('SELECT * FROM ' . PMA_backquote($table))
. '&amp;pos=0">'; . '&amp;pos=0">';
$lnk2 = '<a href="tbl_select.php3?' . $url_query . '">'; $lnk2 = '<a href="tbl_select.php3?' . $url_query . '">';
$lnk3 = '<a href="tbl_properties_export.php3?' . $url_query . '">';
$ln4_stt = (PMA_MYSQL_INT_VERSION >= 40000) $ln4_stt = (PMA_MYSQL_INT_VERSION >= 40000)
? 'TRUNCATE ' ? 'TRUNCATE '
: 'DELETE FROM '; : 'DELETE FROM ';
@@ -43,7 +43,9 @@ if ($num_rows > 0) {
[ <?php echo $lnk4 . "\n"; ?> [ <?php echo $lnk4 . "\n"; ?>
<b><?php echo $strEmpty; ?></b><?php if ($lnk4) echo '</a>'; ?> ]&nbsp;&nbsp;&nbsp; <b><?php echo $strEmpty; ?></b><?php if ($lnk4) echo '</a>'; ?> ]&nbsp;&nbsp;&nbsp;
[ <?php echo $lnk3 . "\n"; ?> [ <?php echo $lnk3 . "\n"; ?>
<b><?php echo $strExport; ?></b><?php if ($lnk3) echo '</a>'; ?> ]&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <b><?php echo $strExport; ?></b><?php if ($lnk3) echo '</a>'; ?> ]&nbsp;&nbsp;&nbsp;
[ <?php echo $lnk5 . "\n"; ?>
<b><?php echo $strOperations; ?></b><?php if ($lnk5) echo '</a>'; ?> ]&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
[ <a href="sql.php3?<?php echo ereg_replace('tbl_properties.php3$', 'db_details.php3', $url_query); ?>&amp;back=tbl_properties.php3&amp;reload=1&amp;sql_query=<?php echo urlencode('DROP TABLE ' . PMA_backquote($table)); ?>&amp;zero_rows=<?php echo urlencode(sprintf($strTableHasBeenDropped, htmlspecialchars($table))); ?>" [ <a href="sql.php3?<?php echo ereg_replace('tbl_properties.php3$', 'db_details.php3', $url_query); ?>&amp;back=tbl_properties.php3&amp;reload=1&amp;sql_query=<?php echo urlencode('DROP TABLE ' . PMA_backquote($table)); ?>&amp;zero_rows=<?php echo urlencode(sprintf($strTableHasBeenDropped, htmlspecialchars($table))); ?>"
onclick="return confirmLink(this, 'DROP TABLE <?php echo PMA_jsFormat($table); ?>')"> onclick="return confirmLink(this, 'DROP TABLE <?php echo PMA_jsFormat($table); ?>')">
<b><?php echo $strDrop; ?></b></a> ] <b><?php echo $strDrop; ?></b></a> ]

235
tbl_properties_operations.php3 Executable file
View File

@@ -0,0 +1,235 @@
<?php
/* $Id$ */
require('./tbl_properties_common.php3');
require('./tbl_properties_table_info.php3');
?>
<ul>
<!-- Change table name -->
<li>
<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="db" value="<?php echo $db; ?>" />
<input type="hidden" name="table" value="<?php echo $table; ?>" />
<input type="hidden" name="reload" value="1" />
<?php echo $strRenameTable; ?>&nbsp;:
<input type="text" size="20" name="new_name" value="<?php echo htmlspecialchars($table); ?>" class="textfield" onfocus="this.select()" />&nbsp;
<input type="submit" value="<?php echo $strGo; ?>" />
</form>
</div>
</li>
<!-- Move and copy table -->
<li style="vertical-align: top">
<div style="margin-bottom: 10px">
<table border="0" cellspacing="0" cellpadding="0" style="vertical-align: top">
<tr>
<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="db" value="<?php echo $db; ?>" />
<input type="hidden" name="table" value="<?php echo $table; ?>" />
<input type="hidden" name="reload" value="1" />
<input type="hidden" name="what" value="data" />
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td nowrap="nowrap">
<?php echo $strMoveTable . "\n"; ?>
</td>
</tr>
<tr>
<td>
<select name="target_db">
<option value=""></option>
<?php
// The function used below is defined in "common.lib.php3"
PMA_availableDatabases('main.php3?lang=' . $lang . '&amp;server=' . $server);
for ($i = 0; $i < $num_dbs; $i++) {
echo ' ';
echo '<option value="' . str_replace('"', '&quot;', $dblist[$i]) . '">' . htmlspecialchars($dblist[$i]) . '</option>';
echo "\n";
} // end for
?>
</select>
&nbsp;<b>.</b>&nbsp;
<input type="text" size="20" name="new_name" value="<?php echo $table; ?>" class="textfield" onfocus="this.select()" />
</td>
</tr>
<tr>
<td align="<?php echo $cell_align_right; ?>" valign="top">
<input type="submit" name="submit_move" value="<?php echo $strGo; ?>" />
</td>
</tr>
</table>
</form>
</td>
<td width="25">&nbsp;</td>
<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="db" value="<?php echo $db; ?>" />
<input type="hidden" name="table" value="<?php echo $table; ?>" />
<input type="hidden" name="reload" value="1" />
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td colspan="2" nowrap="nowrap">
<?php echo $strCopyTable . "\n"; ?>
</td>
</tr>
<tr>
<td colspan="2">
<select name="target_db">
<?php
for ($i = 0; $i < $num_dbs; $i++) {
echo ' ';
echo '<option value="' . str_replace('"', '&quot;', $dblist[$i]) . '"';
if ($dblist[$i] == $db) {
echo ' selected="selected"';
}
echo '>' . htmlspecialchars($dblist[$i]) . '</option>';
echo "\n";
} // end for
?>
</select>
&nbsp;<b>.</b>&nbsp;
<input type="text" size="20" name="new_name" class="textfield" onfocus="this.select()" />
</td>
</tr>
<tr>
<td nowrap="nowrap">
<input type="radio" name="what" value="structure" id="radio_copy_structure" checked="checked" />
<label for="radio_copy_structure"><?php echo $strStrucOnly; ?></label>&nbsp;&nbsp;<br />
<input type="radio" name="what" value="data" id="radio_copy_data" />
<label for="radio_copy_data"><?php echo $strStrucData; ?></label>&nbsp;&nbsp;
</td>
<td align="<?php echo $cell_align_right; ?>" valign="top">
<input type="submit" name="submit_copy" value="<?php echo $strGo; ?>" />
</td>
</tr>
</table>
</form>
</td>
</tr>
</table>
</div>
</li>
<?php
if (PMA_MYSQL_INT_VERSION >= 32322) {
if ($tbl_type == 'MYISAM' or $tbl_type == 'BDB') {
?>
<!-- Table maintenance -->
<li style="vertical-align: top">
<div style="margin-bottom: 10px">
<table border="0" cellspacing="0" cellpadding="0" style="vertical-align: top">
<tr>
<td><?php echo $strTableMaintenance; ?>&nbsp;:&nbsp;</td>
<?php
echo "\n";
if ($tbl_type == 'MYISAM') {
?>
<td>
<a href="sql.php3?<?php echo $url_query; ?>&amp;sql_query=<?php echo urlencode('CHECK TABLE ' . PMA_backquote($table)); ?>">
<?php echo $strCheckTable; ?></a>&nbsp;
<?php echo PMA_showDocuShort('C/H/CHECK_TABLE.html') . "\n"; ?>
</td>
<td>&nbsp;-&nbsp;</td>
<?php
}
echo "\n";
if ($tbl_type == 'MYISAM' || $tbl_type == 'BDB') {
?>
<td>
<a href="sql.php3?<?php echo $url_query; ?>&amp;sql_query=<?php echo urlencode('ANALYZE TABLE ' . PMA_backquote($table)); ?>">
<?php echo $strAnalyzeTable; ?></a>&nbsp;
<?php echo PMA_showDocuShort('A/N/ANALYZE_TABLE.html') . "\n";?>
</td>
<?php
}
echo "\n";
?>
</tr>
<tr>
<td>&nbsp;</td>
<?php
echo "\n";
if ($tbl_type == 'MYISAM') {
?>
<td>
<a href="sql.php3?<?php echo $url_query; ?>&amp;sql_query=<?php echo urlencode('REPAIR TABLE ' . PMA_backquote($table)); ?>">
<?php echo $strRepairTable; ?></a>&nbsp;
<?php echo PMA_showDocuShort('R/E/REPAIR_TABLE.html') . "\n"; ?>
</td>
<td>&nbsp;-&nbsp;</td>
<?php
}
echo "\n";
if ($tbl_type == 'MYISAM' || $tbl_type == 'BDB') {
?>
<td>
<a href="sql.php3?<?php echo $url_query; ?>&amp;sql_query=<?php echo urlencode('OPTIMIZE TABLE ' . PMA_backquote($table)); ?>">
<?php echo $strOptimizeTable; ?></a>&nbsp;
<?php echo PMA_showDocuShort('O/P/OPTIMIZE_TABLE.html') . "\n"; ?>
</td>
<?php
}
echo "\n";
?>
</tr>
</table><br />
</div>
</li>
<?php
} // end MYISAM or BDB case
echo "\n";
} // end MySQL >= 3.23.22
// loic1: "OPTIMIZE" statement is available for MyISAM and BDB tables only and
// MyISAM/BDB tables exists since MySQL 3.23.06/3.23.34
else if (PMA_MYSQL_INT_VERSION >= 32306
&& ($tbl_type == 'MYISAM' or $tbl_type == 'BDB')) {
?>
<!-- Table maintenance -->
<li style="vertical-align: top">
<div style="margin-bottom: 10px">
<?php echo $strTableMaintenance; ?>&nbsp;:&nbsp;
<a href="sql.php3?<?php echo $url_query; ?>&amp;sql_query=<?php echo urlencode('OPTIMIZE TABLE ' . PMA_backquote($table)); ?>">
<?php echo $strOptimizeTable; ?></a>&nbsp;
<?php echo PMA_showDocuShort('O/P/OPTIMIZE_TABLE.html') . "\n"; ?>
</div>
</li>
<?php
echo "\n";
} // end 3.23.06 < MySQL < 3.23.22
?>
<!-- Flushes the table -->
<li>
<a href="sql.php3?<?php echo $url_query; ?>&amp;sql_query=<?php echo urlencode('FLUSH TABLE ' . PMA_backquote($table)); ?>&amp;zero_rows=<?php echo urlencode(sprintf($strTableHasBeenFlushed, htmlspecialchars($table))); if ($cfg['ShowTooltip']) echo '&amp;reload=1'; ?>">
<?php echo $strFlushTable; ?></a>
<br /><br />
</li>
<!-- Deletes the table -->
<li>
<a href="sql.php3?<?php echo ereg_replace('tbl_properties.php3$', 'db_details.php3', $url_query); ?>&amp;back=tbl_properties.php3&amp;reload=1&amp;sql_query=<?php echo urlencode('DROP TABLE ' . PMA_backquote($table)); ?>&amp;zero_rows=<?php echo urlencode(sprintf($strTableHasBeenDropped, htmlspecialchars($table))); ?>"
onclick="return confirmLink(this, 'DROP TABLE <?php echo PMA_jsFormat($table); ?>')">
<?php echo $strDropTable; ?></a>
</li>
</ul>
<?php
/**
* Displays the footer
*/
echo "\n";
require('./footer.inc.php3');
?>