Highlight NULL
git-svn-id: https://adminer.svn.sourceforge.net/svnroot/adminer/trunk@49 7c3ca157-0c34-0410-bff1-cbf682f78f5c
This commit is contained in:
parent
1ff257d79d
commit
9aaaa185b8
|
@ -1,10 +1,10 @@
|
||||||
<?php
|
<?php
|
||||||
page_header(lang('Table') . ": " . htmlspecialchars($_GET["table"]));
|
page_header(lang('Table') . ": " . htmlspecialchars($_GET["table"]));
|
||||||
|
|
||||||
$result = mysql_query("SHOW FULL COLUMNS FROM " . idf_escape($_GET["table"]));
|
$result = mysql_query("SHOW COLUMNS FROM " . idf_escape($_GET["table"]));
|
||||||
echo "<table border='1' cellspacing='0' cellpadding='2'>\n";
|
echo "<table border='1' cellspacing='0' cellpadding='2'>\n";
|
||||||
while ($row = mysql_fetch_assoc($result)) {
|
while ($row = mysql_fetch_assoc($result)) {
|
||||||
echo "<tr><th>" . htmlspecialchars($row["Field"]) . "</th><td>$row[Type]" . ($row["Null"] == "NO" ? " NOT NULL" : "") . "</td></tr>\n";
|
echo "<tr><th>" . htmlspecialchars($row["Field"]) . "</th><td>$row[Type]" . ($row["Null"] == "NO" ? "" : " <i>NULL</i>") . "</td></tr>\n";
|
||||||
}
|
}
|
||||||
echo "</table>\n";
|
echo "</table>\n";
|
||||||
mysql_free_result($result);
|
mysql_free_result($result);
|
||||||
|
|
Loading…
Reference in a new issue