fixed unneded spacing and collapsing on first click
This commit is contained in:
@@ -5,6 +5,13 @@ phpMyAdmin - Changelog
|
||||
$Id$
|
||||
$Source$
|
||||
|
||||
2004-04-28 Garvin Hicking <pma@supergarv.de>
|
||||
* left.php, libraries/left.js: Fixed unneeded spacing between items
|
||||
and wrong collapsion in nested mode (Bug #943140). Removed
|
||||
some debugging non-xhtml tags.
|
||||
* css/phpmyadmin.css.php: Added zero margin/padding to nowrap element
|
||||
for compatibility to the good old nobr-tag
|
||||
|
||||
2004-04-27 Michal Cihar <michal@cihar.com>
|
||||
* calendar.php, libraries/tbl_change.js: Don't reset clock when moving in
|
||||
calendar.
|
||||
|
@@ -280,6 +280,8 @@ form.clock {
|
||||
|
||||
.nowrap {
|
||||
white-space: nowrap;
|
||||
margin: 0px;
|
||||
padding: 0px;
|
||||
}
|
||||
|
||||
li {
|
||||
|
27
left.php
27
left.php
@@ -97,11 +97,11 @@ function PMA_nestedSetHeaderParent($baseid, $key, $keyhistory, $indent, $indent_
|
||||
echo PMA_indent($indent * 6) . '<div class="nowrap"><img src="images/spacer.gif" border="0" width="' . (($indent - 1) * $indent_level) . '" height="9" alt="" /><a class="item" href="' . $GLOBALS['cfg']['DefaultTabDatabase'] . '?' . $GLOBALS['common_url_query'] . '" onclick="if (capable) {expandBase(\'el' . $id . '\', true); return false} else {return true}">';
|
||||
echo '<img name="imEx" id="el' . $id . 'Img" src="images/plus.png" border="0" width="9" height="9" alt="+" /></a>' . "\n";
|
||||
echo PMA_indent($indent * 6) . '<a class="item" href="' . $GLOBALS['cfg']['DefaultTabDatabase'] . '?' . $GLOBALS['common_url_query'] . '" title="' . htmlspecialchars($name) . '" onclick="if (capable) {expandBase(\'el' . $id . '\', false)}"><span class="heada">' . htmlspecialchars($name) . '<bdo dir="' . $GLOBALS['text_dir'] . '"> </bdo></span><span class="headaCnt">(' . $counter . ')</span></a></div>' . "\n";
|
||||
echo PMA_indent($indent * 5) . '</div><id class="PMA_nestedSetHeaderParent">' . "\n";
|
||||
echo PMA_indent($indent * 5) . '</div><!-- class="PMA_nestedSetHeaderParent" -->' . "\n";
|
||||
echo "\n";
|
||||
|
||||
if ($childout) {
|
||||
echo PMA_indent($indent * 5) . '<div id="el' . $id . 'Child" class="child" ' . $on_mouse . '>' . "\n";
|
||||
echo PMA_indent($indent * 5) . '<div id="el' . $id . 'Child" class="child nowrap" ' . $on_mouse . '>' . "\n";
|
||||
}
|
||||
}
|
||||
|
||||
@@ -124,15 +124,15 @@ function PMA_nestedSetHeader($baseid, $tablestack, $keyhistory, $indent, $indent
|
||||
}
|
||||
|
||||
if ($headerOut) {
|
||||
echo PMA_indent($indent * 5) . '</div><id class="PMA_nestedSetHeader">' . "\n";
|
||||
echo PMA_indent($indent * 5) . '</div><!-- class="PMA_nestedSetHeader" -->' . "\n";
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if ($firstGroup && $firstGroupClose) {
|
||||
echo PMA_indent($indent * 4) . '</div><id class="PMA_nestedSetHeader2">' . "\n";
|
||||
echo PMA_indent($indent * 4) . '</div><!-- class="PMA_nestedSetHeader2" -->' . "\n";
|
||||
} elseif ($firstGroup) {
|
||||
echo PMA_indent($indent * 4) . '<id spacer="div omitted" class="PMA_nestedSetHeader2">' . "\n";
|
||||
echo PMA_indent($indent * 4) . '<!-- spacer="div omitted" class="PMA_nestedSetHeader2" -->' . "\n";
|
||||
}
|
||||
}
|
||||
|
||||
@@ -163,19 +163,19 @@ function PMA_nestedSet($baseid, $tablestack, $key = '__protected__', $keyhistory
|
||||
$loops = 0;
|
||||
foreach($tablestack['pma_name'] AS $tkey => $tval) {
|
||||
|
||||
echo PMA_indent($indent * 5) . '<div class="nowrap"><img src="images/spacer.gif" border="0" width="' . (($indent+$extra_indent) * $indent_level) . '" height="9" alt="" />';
|
||||
echo PMA_indent($indent * 5) . '<img src="images/spacer.gif" border="0" width="' . (($indent+$extra_indent) * $indent_level) . '" height="9" alt="" />';
|
||||
$items = explode("\n", $tablestack['pma_list_item'][$tkey]);
|
||||
foreach($items AS $ikey => $ival) {
|
||||
echo "\n";
|
||||
echo PMA_indent(($indent * 5)) . $ival;
|
||||
}
|
||||
echo "</div>\n";
|
||||
echo "\n";
|
||||
|
||||
$loops++;
|
||||
}
|
||||
|
||||
if ($divClose) {
|
||||
echo PMA_indent($indent * 5) . '</div><id space="putting omitted div" class="PMA_nestedSet2">';
|
||||
echo PMA_indent($indent * 5) . '</div><!-- space="putting omitted div" class="PMA_nestedSet2" -->';
|
||||
}
|
||||
|
||||
} elseif (is_array($tablestack)) {
|
||||
@@ -592,9 +592,9 @@ if ($num_dbs > 1) {
|
||||
$table_array[$table] .= ' <img src="images/button_smallbrowse.png" width="10" height="10" border="0" alt="' . $strBrowse . ': ' . $url_title . '" title="' . $strBrowse . ': ' . $url_title . '" /></a><bdo dir="' . $text_dir . '"> </bdo>' . "\n";
|
||||
|
||||
if (PMA_USR_BROWSER_AGENT == 'IE') {
|
||||
$table_array[$table] .= ' <span class="tblItem"><a class="tblItem" id="tbl_' . md5($table) . '" title="' . $url_title . '" target="phpmain' . $hash . '" href="' . $cfg['DefaultTabTable'] . '?' . $common_url_query . '&table=' . urlencode($table) . '">' . ($alias != '' && $cfg['ShowTooltipAliasTB'] ? $alias : htmlspecialchars($table)) . '</a></span></div><br />' . "\n";
|
||||
$table_array[$table] .= ' <span class="tblItem"><a class="tblItem" id="tbl_' . md5($table) . '" title="' . $url_title . '" target="phpmain' . $hash . '" href="' . $cfg['DefaultTabTable'] . '?' . $common_url_query . '&table=' . urlencode($table) . '">' . ($alias != '' && $cfg['ShowTooltipAliasTB'] ? $alias : htmlspecialchars($table)) . '</a></span></div>' . "\n";
|
||||
} else {
|
||||
$table_array[$table] .= ' <a class="tblItem" id="tbl_' . md5($table) . '" title="' . $url_title . '" target="phpmain' . $hash . '" href="' . $cfg['DefaultTabTable'] . '?' . $common_url_query . '&table=' . urlencode($table) . '">' . ($alias != '' && $cfg['ShowTooltipAliasTB'] ? $alias : htmlspecialchars($table)) . '</a></div><br />' . "\n";
|
||||
$table_array[$table] .= ' <a class="tblItem" id="tbl_' . md5($table) . '" title="' . $url_title . '" target="phpmain' . $hash . '" href="' . $cfg['DefaultTabTable'] . '?' . $common_url_query . '&table=' . urlencode($table) . '">' . ($alias != '' && $cfg['ShowTooltipAliasTB'] ? $alias : htmlspecialchars($table)) . '</a></div>' . "\n";
|
||||
}
|
||||
|
||||
$table_title[$table] = htmlspecialchars($table);
|
||||
@@ -745,7 +745,7 @@ else if ($num_dbs == 1) {
|
||||
<a class="item" href="<?php echo $cfg['DefaultTabDatabase']; ?>?<?php echo $common_url_query; ?>">
|
||||
<span class="heada"><?php echo ($db_tooltip != '' && $cfg['ShowTooltipAliasDB'] ? htmlspecialchars($db_tooltip) : htmlspecialchars($db)); ?><bdo dir="<?php echo($text_dir); ?>"> </bdo></span><span class="headaCnt">(<?php echo $num_tables_disp; ?>)</span></a>
|
||||
</div>
|
||||
<div id="el2Child" class="child" style="margin-bottom: 5px">
|
||||
<div id="el2Child" class="child nowrap" style="margin-bottom: 5px">
|
||||
<?php
|
||||
}
|
||||
|
||||
@@ -760,21 +760,20 @@ else if ($num_dbs == 1) {
|
||||
: '';
|
||||
$book_sql_query = PMA_queryBookmarks($db, $cfg['Bookmark'], '\'' . PMA_sqlAddslashes($table) . '\'', 'label');
|
||||
|
||||
echo '<div class="nowrap">';
|
||||
if ($cfg['LeftFrameLight']) {
|
||||
echo "\n";
|
||||
?>
|
||||
<a target="phpmain<?php echo $hash; ?>" href="sql.php?<?php echo $common_url_query; ?>&table=<?php echo urlencode($table); ?>&sql_query=<?php echo (isset($book_sql_query) && $book_sql_query != FALSE ? urlencode($book_sql_query) : urlencode('SELECT * FROM ' . PMA_backquote($table))); ?>&pos=0&goto=<?php echo $cfg['DefaultTabTable']; ?>" title="<?php echo $strBrowse . ': ' . $url_title; ?>">
|
||||
<img src="images/button_smallbrowse.png" width="10" height="10" border="0" alt="<?php echo $strBrowse . ': ' . $url_title; ?>" /></a><bdo dir="<?php echo $text_dir; ?>"> </bdo>
|
||||
<a class="tblItem" id="tbl_<?php echo md5($table); ?>" title="<?php echo $url_title; ?>" target="phpmain<?php echo $hash; ?>" href="<?php echo $cfg['DefaultTabTable']; ?>?<?php echo $common_url_query; ?>&table=<?php echo urlencode($table); ?>">
|
||||
<?php echo ($alias != '' && $cfg['ShowTooltipAliasTB'] ? $alias : htmlspecialchars($table)); ?></a></div><br />
|
||||
<?php echo ($alias != '' && $cfg['ShowTooltipAliasTB'] ? $alias : htmlspecialchars($table)); ?></a><br />
|
||||
<?php
|
||||
} else {
|
||||
$list_item = '<a target="phpmain' . $hash . '" href="sql.php?' . $common_url_query . '&table=' . urlencode($table) . '&sql_query=' . (isset($book_sql_query) && $book_sql_query != FALSE ? urlencode($book_sql_query) : urlencode('SELECT * FROM ' . PMA_backquote($table))) . '&pos=0&goto=' . $cfg['DefaultTabTable'] . '" title="' . $strBrowse . ': ' . $url_title . '">';
|
||||
$list_item .= '<img src="images/button_smallbrowse.png" width="10" height="10" border="0" alt="' . $strBrowse . ': ' . $url_title . '" /></a>';
|
||||
$list_item .= '<bdo dir="' . $text_dir . '"> </bdo>' . "\n";
|
||||
$list_item .= '<a class="tblItem" id="tbl_' . md5($table) . '" title="' . $url_title . '" target="phpmain' . $hash . '" href="' . $cfg['DefaultTabTable'] . '?' . $common_url_query . '&table=' . urlencode($table) . '">';
|
||||
$list_item .= ($alias != '' && $cfg['ShowTooltipAliasTB'] ? $alias : htmlspecialchars($table)) . '</a></div><br />';
|
||||
$list_item .= ($alias != '' && $cfg['ShowTooltipAliasTB'] ? $alias : htmlspecialchars($table)) . '</a><br />';
|
||||
|
||||
// garvin: Check whether to display nested sets
|
||||
if (!empty($cfg['LeftFrameTableSeparator'])) {
|
||||
|
@@ -126,7 +126,7 @@ function initIt()
|
||||
for (i = 0; i < tempCollCnt; i++) {
|
||||
if (tempColl[i].id == expandedDb)
|
||||
tempColl[i].style.display = 'block';
|
||||
else if (tempColl[i].className == 'child')
|
||||
else if (tempColl[i].className == 'child' || tempColl[i].className == 'child nowrap')
|
||||
tempColl[i].style.display = 'none';
|
||||
}
|
||||
} // end of the DOM case
|
||||
@@ -136,7 +136,7 @@ function initIt()
|
||||
for (i = 0; i < tempCollCnt; i++) {
|
||||
if (tempColl(i).id == expandedDb)
|
||||
tempColl(i).style.display = 'block';
|
||||
else if (tempColl(i).className == 'child')
|
||||
else if (tempColl(i).className == 'child' || tempColl(i).className == 'child nowrap')
|
||||
tempColl(i).style.display = 'none';
|
||||
}
|
||||
} // end of the IE4 case
|
||||
|
Reference in New Issue
Block a user