beautified code
This commit is contained in:
@@ -7,6 +7,7 @@ $Source$
|
|||||||
|
|
||||||
2002-04-28 Lo<4C>c Chapeaux <lolo@phpheaven.net>
|
2002-04-28 Lo<4C>c Chapeaux <lolo@phpheaven.net>
|
||||||
* tbl_properties.php3, line 395: replaced a "require" by an include.
|
* tbl_properties.php3, line 395: replaced a "require" by an include.
|
||||||
|
* tbl_properties_links.php3: beautified code.
|
||||||
|
|
||||||
2002-04-27 Marc Delisle <lem9@users.sourceforge.net>
|
2002-04-27 Marc Delisle <lem9@users.sourceforge.net>
|
||||||
* tbl_properties.php3, new tbl_properties_links.php3:
|
* tbl_properties.php3, new tbl_properties_links.php3:
|
||||||
|
@@ -1,47 +1,39 @@
|
|||||||
<?php
|
<?php
|
||||||
/* $Id$ */
|
/* $Id$ */
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Prepares links
|
||||||
|
*/
|
||||||
|
if ($num_rows > 0) {
|
||||||
|
$lnk1 = '<a href="sql.php3?' . $url_query
|
||||||
|
. '&sql_query=' . urlencode('SELECT * FROM ' . PMA_backquote($table))
|
||||||
|
. '&pos=0">';
|
||||||
|
$lnk2 = '<a href="tbl_select.php3?' . $url_query . '">';
|
||||||
|
$ln4_stt = (PMA_MYSQL_INT_VERSION >= 40000)
|
||||||
|
? 'TRUNCATE '
|
||||||
|
: 'DELETE FROM ';
|
||||||
|
$lnk4 = '<a href="sql.php3?' . $url_query . '&sql_query='
|
||||||
|
. urlencode($ln4_stt . PMA_backquote($table))
|
||||||
|
. '&zero_rows='
|
||||||
|
. urlencode(sprintf($strTableHasBeenEmptied, htmlspecialchars($table)))
|
||||||
|
. '"' . "\n"
|
||||||
|
. ' onclick="return confirmLink(this, \'' . $ln4_stt . PMA_jsFormat($table) . '\')">';
|
||||||
|
} else {
|
||||||
|
$lnk1 = '';
|
||||||
|
$lnk2 = '';
|
||||||
|
$lnk4 = '';
|
||||||
|
}
|
||||||
?>
|
?>
|
||||||
<p>
|
<p>
|
||||||
[ <?php if ($num_rows > 0) {
|
[ <?php echo $lnk1 . "\n"; ?>
|
||||||
?>
|
<b><?php echo $strBrowse; ?></b><?php if ($lnk1) echo '</a>'; ?> ]
|
||||||
<a href="sql.php3?<?php echo $url_query; ?>&sql_query=<?php echo urlencode('SELECT * FROM ' . PMA_backquote($table)); ?>&pos=0">
|
[ <?php echo $lnk2 . "\n"; ?>
|
||||||
<?php
|
<b><?php echo $strSelect; ?></b><?php if ($lnk2) echo '</a>'; ?> ]
|
||||||
} // end if
|
|
||||||
?>
|
|
||||||
<b><?php echo $strBrowse; ?></b></a> ]
|
|
||||||
[ <?php if ($num_rows > 0) {
|
|
||||||
?>
|
|
||||||
<a href="tbl_select.php3?<?php echo $url_query; ?>">
|
|
||||||
<?php
|
|
||||||
} // end if
|
|
||||||
?>
|
|
||||||
<b><?php echo $strSelect; ?></b></a> ]
|
|
||||||
[ <a href="tbl_change.php3?<?php echo $url_query; ?>">
|
[ <a href="tbl_change.php3?<?php echo $url_query; ?>">
|
||||||
<b><?php echo $strInsert; ?></b></a> ]
|
<b><?php echo $strInsert; ?></b></a> ]
|
||||||
[ <?php
|
[ <?php echo $lnk4 . "\n"; ?>
|
||||||
if ($num_rows > 0) {
|
<b><?php echo $strEmpty; ?></b><?php if ($lnk4) echo '</a>'; ?> ]
|
||||||
echo '<a href="sql.php3?' . $url_query . '&sql_query=';
|
|
||||||
if (PMA_MYSQL_INT_VERSION >= 40000) {
|
|
||||||
echo urlencode('TRUNCATE ' . PMA_backquote($table))
|
|
||||||
. '&zero_rows='
|
|
||||||
. urlencode(sprintf($strTableHasBeenEmptied, htmlspecialchars($table)))
|
|
||||||
. '"' . "\n"
|
|
||||||
. ' onclick="return confirmLink(this, \'TRUNCATE ';
|
|
||||||
} // end if
|
|
||||||
else {
|
|
||||||
echo urlencode('DELETE FROM ' . PMA_backquote($table))
|
|
||||||
. '&zero_rows='
|
|
||||||
. urlencode(sprintf($strTableHasBeenEmptied, htmlspecialchars($table)))
|
|
||||||
. '"'
|
|
||||||
. "\n"
|
|
||||||
. ' onclick="return confirmLink(this, \'DELETE FROM ';
|
|
||||||
} // end else
|
|
||||||
echo PMA_jsFormat($table)
|
|
||||||
. '\')">'
|
|
||||||
. "\n";
|
|
||||||
} // end if
|
|
||||||
?>
|
|
||||||
<b><?php echo $strEmpty; ?></b></a> ]
|
|
||||||
[ <a href="sql.php3?<?php echo ereg_replace('tbl_properties.php3$', 'db_details.php3', $url_query); ?>&back=tbl_properties.php3&reload=1&sql_query=<?php echo urlencode('DROP TABLE ' . PMA_backquote($table)); ?>&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); ?>&back=tbl_properties.php3&reload=1&sql_query=<?php echo urlencode('DROP TABLE ' . PMA_backquote($table)); ?>&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> ]
|
||||||
|
Reference in New Issue
Block a user