Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Centralize nowrap

git-svn-id: https://adminer.svn.sourceforge.net/svnroot/adminer/trunk@1300 7c3ca157-0c34-0410-bff1-cbf682f78f5c
  • Loading branch information...
commit dfe2540380e453fc91d422a12fe1380770646597 1 parent 4df6acc
jakubvrana authored
2  adminer/create.inc.php
View
@@ -158,7 +158,7 @@
<?php echo html_select("Collation", array("" => "(" . lang('collation') . ")") + $collations, $row["Collation"]); ?>
<input type="submit" value="<?php echo lang('Save'); ?>">
</p>
-<table cellspacing="0" id="edit-fields">
+<table cellspacing="0" id="edit-fields" class="nowrap">
<?php $column_comments = edit_fields($row["fields"], $collations, "TABLE", $suhosin, $foreign_keys); ?>
</table>
<p>
6 adminer/include/editing.inc.php
View
@@ -188,7 +188,7 @@ function edit_fields($fields, $collations, $type = "TABLE", $allowed = 0, $forei
}
}
?>
-<thead><tr>
+<thead><tr class="wrap">
<?php if ($type == "PROCEDURE") { ?><td>&nbsp;<?php } ?>
<th><?php echo ($type == "TABLE" ? lang('Column name') : lang('Parameter name')); ?>
<td><?php echo lang('Type'); ?><textarea id="enum-edit" rows="4" cols="10" style="display: none;" onblur="editingLengthBlur(this);"></textarea>
@@ -218,11 +218,11 @@ function edit_fields($fields, $collations, $type = "TABLE", $allowed = 0, $forei
<?php if ($type == "TABLE") { ?>
<td><?php echo checkbox("fields[$i][null]", 1, $field["null"]); ?>
<td><input type="radio" name="auto_increment_col" value="<?php echo $i; ?>"<?php if ($field["auto_increment"]) { ?> checked<?php } ?>>
-<td class="nowrap hidden"><?php echo checkbox("fields[$i][has_default]", 1, $field["has_default"]); ?><input name="fields[<?php echo $i; ?>][default]" value="<?php echo h($field["default"]); ?>" onchange="this.previousSibling.checked = true;">
+<td class="hidden"><?php echo checkbox("fields[$i][has_default]", 1, $field["has_default"]); ?><input name="fields[<?php echo $i; ?>][default]" value="<?php echo h($field["default"]); ?>" onchange="this.previousSibling.checked = true;">
<td<?php echo ($column_comments ? "" : " class='hidden'"); ?>><input name="fields[<?php echo $i; ?>][comment]" value="<?php echo h($field["comment"]); ?>" maxlength="255">
<?php } ?>
<?php
- echo "<td class='nowrap'><input type='image' name='add[$i]' src='../adminer/static/plus.gif' alt='+' title='" . lang('Add next') . "' onclick='return !editingAddRow(this, $allowed, 1);'>";
+ echo "<td><input type='image' name='add[$i]' src='../adminer/static/plus.gif' alt='+' title='" . lang('Add next') . "' onclick='return !editingAddRow(this, $allowed, 1);'>";
echo "&nbsp;<input type='image' name='drop_col[$i]' src='../adminer/static/cross.gif' alt='x' title='" . lang('Remove') . "' onclick='return !editingRemoveRow(this);'>";
echo "&nbsp;<input type='image' name='up[$i]' src='../adminer/static/up.gif' alt='^' title='" . lang('Move up') . "'>";
echo "&nbsp;<input type='image' name='down[$i]' src='../adminer/static/down.gif' alt='v' title='" . lang('Move down') . "'>";
11 adminer/procedure.inc.php
View
@@ -39,9 +39,14 @@
?>
<form action="" method="post" id="form">
-<table cellspacing="0">
-<?php edit_fields($row["fields"], $collations, $routine); ?>
-<?php if (isset($_GET["function"])) { ?><tr><td><?php echo lang('Return type'); edit_type("returns", $row["returns"], $collations); ?><?php } ?>
+<table cellspacing="0" class="nowrap">
+<?php
+edit_fields($row["fields"], $collations, $routine);
+if (isset($_GET["function"])) {
+ echo "<tr><td>" . lang('Return type');
+ edit_type("returns", $row["returns"], $collations);
+}
+?>
</table>
<p><textarea name="definition" rows="10" cols="80" style="width: 98%;"><?php echo h($row["definition"]); ?></textarea>
<p>
2  adminer/static/editing.js
View
@@ -243,7 +243,7 @@ function editingLengthBlur(edit) {
function columnShow(checked, column) {
var trs = document.getElementById('edit-fields').getElementsByTagName('tr');
for (var i=0; i < trs.length; i++) {
- trs[i].getElementsByTagName('td')[column].className = (checked ? 'nowrap' : 'hidden');
+ trs[i].getElementsByTagName('td')[column].className = (checked ? '' : 'hidden');
}
}
Please sign in to comment.
Something went wrong with that request. Please try again.