Hallo,
ich habe für meine Webseite folgende Tabelle eingebaut, die man auf- und wieder zuklappen kann (ich glaube, die Anregung hatte ich sogar hier aus dem Forum). Das funktioniert ganz prima.
Das Problem dabei ist, dass sobald ich viele Unterpunkte "aufgeklappt" habe und die Anzeige größer wird als das Browser-Fenster, dann bekomme ich keine Scrollbars (so wie man das normalweise ja gewohnt ist, und was eigentlich automatisch funktionieren sollte). Die untersten Items verschwinden dann einfach ...
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Homepage</title>
<link href="css_default.css" rel="stylesheet" type="text/css" />
<script language="javascript">
window.defaultStatus = "Homepage";
<!--
var zeilen;
function init () {
zeilen = document.getElementsByTagName('tr');
}
function einaus (was) {
for (i=0; i<zeilen.length ; i++ ) {
if(zeilen[i].id.indexOf(was)>=0) {
if(zeilen[i].style.display=='none') {
if(document.all&&!window.opera) {
zeilen[i].style.display='block';
} else {
zeilen[i].style.display='table-row';
}
} else {
zeilen[i].style.display='none';
}
}
}
}
</script>
</head>
<body onLoad="init()">
<table width="100%" border="1">
<tr>
<td colspan="2"><div align="left"><a href="#" class="navLink" onClick="einaus('ML')">ML</a></div></td>
</tr>
<tr id="ML" style="display:none">
<td width="5%" class="navLink_klein"><img src="Icons/pfeil4.gif" alt="" width="9" height="9" /></td>
<td width="95%" class="navLink_klein"><a href="ml_KYC.html" target="mainFrame" class="navLink_klein">ML (KYC)</a></td>
</tr>
<tr id="ML" style="display:none">
<td class="navLink_klein"><img src="Icons/pfeil4.gif" alt="" width="9" height="9" /></td>
<td class="navLink_klein"><a href="ml_AO.html" target="mainFrame" class="navLink_klein">ML (AO)</a></td>
</tr>
<tr>
<td colspan="2"><a href="#" class="navLink" onClick="einaus('Comp')">Comp</a></td>
</tr>
<tr id="Comp" style="display:none">
<td class="navLink_klein" ><img src="Icons/pfeil4.gif" alt="" width="9" height="9" /></td>
<td class="navLink_klein" ><a href="comp_FSA.html" target="mainFrame" class="navLink_klein">Comp FSA</a></td>
</tr>
<tr id="Comp" style="display:none">
<td class="navLink_klein" ><img src="Icons/pfeil4.gif" alt="" width="9" height="9" /></td>
<td class="navLink_klein" ><a href="comp_BC.html" target="mainFrame" class="navLink_klein">Comp BC</a></td>
</table>
</body>
</html>
Die Tabelle ist natürlich wesentlich größer.
Ich hatte es auch schon einmal mit scrolling="yes" im Frame probiert, aber das bringt nichts... (ist glaube ich eh default).
Weiss da jemand Rat ?
Vielen Dank schonmal im Voraus