Java Html Menü oder so

Status
Nicht offen für weitere Antworten.
Sorry, musste gestern dann weg. Du hast die Frage nicht so wirklich beantwortet. Sollen die einzelnen - ich nenn sie jetzt mal Untermenüs - also sollen die jetzt leicht versetzt unter die jeweilgen Hauptpunkte und das in jeder Auflösung oder wie?
 
Ich sag doch du musst noch für ne feste Tabellenbreite sorgen. Schreib einfach width="[Summe der Spaltenbreiten in der Navigationstabelle]" in den <table>-tag der Navigationstabelle und richte die anderen Tabellen danach aus:
HTML:
<!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>
 <title>Unbenanntes Dokument</title>
 <style type="text/css"><!--
 td {
 width: 150px;
 }
 --></style>
 </head>
   <script type="text/javascript">
 
   var subs=new Array('sub1','sub2','sub3','sub4','sub5');
 
   function hideall(){
 	for(x=0; x<subs.length;x++){
 	  document.getElementById(subs[x]).style.visibility='hidden';
 	}
   }
 
   function display(mode,ele){
 	if(mode=='s'){
 	  hideall();
 	  document.getElementById(ele).style.visibility='visible';
 	}else{
 	  document.getElementById(ele).style.visibility='hidden';
 	}
   }
   </script>
 
 
 <body>
 <div>
   <table border="1" cellspacing="0" cellpadding="0" width="500px">
 	<tr>
 	  <td style="width:100px;" height="20" onMouseOver="display('s','sub1')">Test</td>
 	  <td style="width:100px;" height="20" onMouseOver="display('s','sub2')">Test</td>
 	  <td style="width:100px;" height="20" onMouseOver="display('s','sub3')">Test</td>
 	  <td style="width:100px;" height="20" onMouseOver="display('s','sub4')">Test</td>
 	  <td style="width:100px;" height="20" onMouseOver="display('s','sub5')">Test</td>
 	</tr>
   </table>
 </div>
 
 <div style="visibility:hidden; margin-left:0px; position:absolute; top:40px;" id="sub1" onClick="display('h','sub1')">
   <table height="90" border="1"  cellspacing="0" cellpadding="0">
 	<tr><td style="width:150px;">Test</td></tr>
 	<tr><td style="width:150px;">Test</td></tr>
 	<tr><td style="width:150px;">Test</td></tr>
 	<tr><td style="width:150px;">Test</td></tr>
 	<tr><td style="width:150px;">Test</td></tr>
   </table>
 </div>
 
 <span style="visibility:hidden; margin-left:100px; position:absolute; top:40px;" id="sub2" onClick="display('h','sub2')">
   <table height="90" border="1"  cellspacing="0" cellpadding="0">
 	<tr><td style="width:150px;">Test2</td></tr>
 	<tr><td style="width:150px;">Test</td></tr>
 	<tr><td style="width:150px;">Test</td></tr>
 	<tr><td style="width:150px;">Test</td></tr>
 	<tr><td style="width:150px;">Test</td></tr>
   </table>
 </span>
 
 <div style="visibility:hidden; margin-left:200px; position:absolute; top:40px;" id="sub3" onClick="display('h','sub3')">
   <table height="90" border="1"  cellspacing="0" cellpadding="0">
 	<tr><td style="width:150px;">Test3</td></tr>
 	<tr><td style="width:150px;">Test</td></tr>
 	<tr><td style="width:150px;">Test</td></tr>
 	<tr><td style="width:150px;">Test</td></tr>
 	<tr><td style="width:150px;">Test</td></tr>
   </table>
 </div>
 
 <div style="visibility:hidden; margin-left:300px; position:absolute; top:40px;" id="sub4" onClick="display('h','sub4')">
   <table height="90" border="1"  cellspacing="0" cellpadding="0">
 	<tr><td style="width:150px;">Test4</td></tr>
 	<tr><td style="width:150px;">Test</td></tr>
 	<tr><td style="width:150px;">Test</td></tr>
 	<tr><td style="width:150px;">Test</td></tr>
 	<tr><td style="width:150px;">Test</td></tr>
   </table>
 </div>
 
 <div style="visibility:hidden; margin-left:400px; position:absolute; top:40px;" id="sub5" onClick="display('h','sub5')">
   <table height="90" border="1" cellspacing="0" cellpadding="0">
 	<tr><td style="width:150px;">Test5</td></tr>
 	<tr><td style="width:150px;">Test</td></tr>
 	<tr><td style="width:150px;">Test</td></tr>
 	<tr><td style="width:150px;">Test</td></tr>
 	<tr><td style="width:150px;">Test</td></tr>
   </table>
 </div>
 
 </body>
 </html>
 
Status
Nicht offen für weitere Antworten.
Zurück