removed references to 2.4.1 release from docs
[phpmyadmin/crack.git] / tbl_properties_links.php3
blob419df0bd608efe41d86736f0bd09ca84d4363bf8
1 <?php
2 /* $Id$ */
3 // vim: expandtab sw=4 ts=4 sts=4:
6 /**
7 * Sets error reporting level
8 */
9 error_reporting(E_ALL);
12 /**
13 * Count amount of navigation tabs
15 $db_details_links_count_tabs = 0;
18 /**
19 * Prepares links
21 include('./libraries/bookmark.lib.php3');
22 $book_sql_query = PMA_queryBookmarks($db, $cfg['Bookmark'], '\'' . PMA_sqlAddslashes($table) . '\'', 'label');
24 if ($table_info_num_rows > 0) {
25 $lnk2 = 'sql.php3';
26 $arg2 = $url_query
27 . '&amp;sql_query=' . (isset($book_sql_query) && $book_sql_query != FALSE ? urlencode($book_sql_query) : urlencode('SELECT * FROM ' . PMA_backquote($table)))
28 . '&amp;pos=0';
29 $lnk4 = 'tbl_select.php3';
30 $arg4 = $url_query;
31 $ln6_stt = (PMA_MYSQL_INT_VERSION >= 40000)
32 ? 'TRUNCATE TABLE '
33 : 'DELETE FROM ';
34 $lnk6 = 'sql.php3';
35 $arg6 = $url_query . '&amp;sql_query='
36 . urlencode($ln6_stt . PMA_backquote($table))
37 . '&amp;zero_rows='
38 . urlencode(sprintf($strTableHasBeenEmptied, htmlspecialchars($table)));
39 $att6 = 'class="drop" onclick="return confirmLink(this, \'' . $ln6_stt . PMA_jsFormat($table) . '\')"';
40 } else {
41 $lnk2 = '';
42 $arg2 = '';
43 $lnk4 = '';
44 $arg4 = '';
45 $lnk6 = '';
46 $arg6 = '';
47 $att6 = '';
50 // The 'back' is supposed to be set to the current sub-page. This is necessary
51 // when you have js deactivated, you click on Drop, then click cancel, and want
52 // to get back to the same sub-page.
53 $arg7 = ereg_replace('tbl_properties[^.]*.php3$', 'db_details.php3', $url_query) . '&amp;reload=1&amp;purge=1&amp;sql_query=' . urlencode('DROP TABLE ' . PMA_backquote($table) ) . '&amp;zero_rows=' . urlencode(sprintf($strTableHasBeenDropped, htmlspecialchars($table)));
54 $att7 = 'class="drop" onclick="return confirmLink(this, \'DROP TABLE ' . PMA_jsFormat($table) . '\')"';
57 /**
58 * Displays links
61 if ($cfg['LightTabs']) {
62 echo '&nbsp;';
63 } else {
64 echo '<table border="0" cellspacing="0" cellpadding="3" width="100%" class="tabs">
65 <tr>
66 <td width="8">&nbsp;</td>';
69 echo PMA_printTab($strStructure, 'tbl_properties_structure.php3', $url_query);
70 echo PMA_printTab($strBrowse, $lnk2, $arg2);
71 echo PMA_printTab($strSQL, 'tbl_properties.php3', $url_query);
72 echo PMA_printTab($strSelect, $lnk4, $arg4);
73 echo PMA_printTab($strInsert, 'tbl_change.php3', $url_query);
74 echo PMA_printTab($strExport, 'tbl_properties_export.php3', $url_query);
75 echo PMA_printTab($strOperations, 'tbl_properties_operations.php3', $url_query);
76 if (PMA_MYSQL_INT_VERSION >= 32322) {
77 echo PMA_printTab($strOptions, 'tbl_properties_options.php3', $url_query);
79 echo PMA_printTab($strEmpty, $lnk6, $arg6, $att6);
80 echo PMA_printTab($strDrop, 'sql.php3', $arg7, $att7);
81 echo "\n";
83 if (!$cfg['LightTabs']) {
84 echo '</tr></table>';
85 } else {
86 echo '<br />';
89 ?><br />