Jetzt Mitglied werden
Kostenlos registrieren und die vielen Vorteile der Webmasterpro-Mitgliedschaft nutzen.
Forum - Entwicklung
- Markup (HTML, XML, etc.) und CSS
- Skriptsprachen (PHP, Javascript, etc.)
- Datenbanken (SQL)
- CMS und Frameworks
- Flash und ActionScript
Info: Der Stern signalisiert, dass neue Beiträge vorhanden sind.
Alle Foren - Übersicht
Portal aktuelle Themen
Design aktuelle Themen
Server aktuelle Themen
- Webhosting und Webspace
- Betriebssysteme (Windows, Linux, etc.)
- Serveradministration
- Überwachung, Sicherheit und Backups
Management aktuelle Themen
Über Webmasterpro.de
Das Portal wird betrieben und entwickelt durch die Team23 Agentur. Die Augsbuger Agentur hat sich auf Community Software und die Entwicklung von Webportalen spezialisiert.
Markup (HTML, XML, etc.) und CSS - Forum
Derzeit sind Sie als Gast in unserem Forum aktiv. Für das Schreiben registrieren Sie sich bitte. Unser Forum ist eine Austauschplattform für Webworker zum Kommunizieren, Helfen, Informieren und Hilfe finden. Auf der rechten Seiten finden Sie eine Forenübersicht über alle Bereiche des Webmaster-Forums. Unterhalb finden Sie alle aktuellen Themen.
In diesem Forum sollen begleitend zu unserem CSS Portal und HTML-Bereich konkrete Fragen zu HTML und CSS diskutiert werden. Bitte immer die Suchfunktion nutzen bevor du eine Frage stellst.
menue in 3 ebenen
hallo leute,
ich habe ein dringendes problem, an dem ich mich festgebissen habe. folgendes:
in meiner navigation brauche ich die 3. ebene. also wenn ich auf "produktdesign" klicke, soll "buildings" als unterpunkt erscheinen. wenn man auf "buildings" klickt auf "geniax", "stratos", "tornado".
vielleicht ist's nur ein kleines problem :(
danke im voraus
das ist der inhalt der css-datei:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 | .bar-menu {
width: 240px;
}
.bar-menu .box1 {
background-color: #f5f5f5;
color: #373737;
font-weight: normal;
font-size: 11px;
font-family: Verdana, Geneva, sans-serif;
padding: 4px 28px 9px;
cursor: default;
position: relative;
text-decoration: none;
}
.bar-menu .box1-hover {
background-color: #fff;
color: #373737;
font-weight: bold;
font-size: 11px;
font-family: Verdana, Geneva, sans-serif;
padding: 4px 28px 9px;
cursor: default;
position: relative;
}
.bar-menu .box1-open {
background-color: #f5f5f5;
color: #373737;
font-weight: bold;
font-size: 11px;
font-family: Verdana, Geneva, sans-serif;
padding: 4px 28px 9px;
cursor: default;
position: relative;
}
.bar-menu .box1-open-hover {
background-color: #f5f5f5;
color: #373737;
font-weight: bold;
font-size: 11px;
font-family: Verdana, Geneva, sans-serif;
padding: 4px 28px 9px;
cursor: default;
position: relative;
}
.bar-menu .box1 img, .bar-menu .box1-hover img, .bar-menu .box1-open img, .bar-menu .box1-open-hover img {
position: absolute;
top: 6px;
right: 6px;
}
.bar-menu .box2 {
background-color: #FFF;
color: #373737;
font-weight: normal;
font-size: 11px;
font-family: Verdana, Geneva, sans-serif;
padding: 4px 28px 9px;
cursor: default;
position: relative;
text-decoration: none;
}
.bar-menu .box2-hover {
background-color: #fff;
color: #373737;
font-weight: bold;
font-size: 11px;
font-family: Verdana, Geneva, sans-serif;
padding: 4px 28px 9px;
cursor: default;
position: relative;
}
.bar-menu .box2-open {
background-color: #FFF;
color: #373737;
font-weight: bold;
font-size: 11px;
font-family: Verdana, Geneva, sans-serif;
padding: 4px 28px 9px;
cursor: default;
position: relative;
}
.bar-menu .box2-open-hover {
background-color: #f5f5f5;
color: #373737;
font-weight: bold;
font-size: 11px;
font-family: Verdana, Geneva, sans-serif;
padding: 4px 28px 9px;
cursor: default;
position: relative;
}
.bar-menu .box2 img, .bar-menu .box2-hover img, .bar-menu .box2-open img, .bar-menu .box2-open-hover img {
position: absolute;
top: 6px;
right: 6px;
}
.bar-menu .section {
background-color: #fff;
font-family: Verdana, Geneva, sans-serif;
font-size: 11px;
padding: 4px 41px 9px;
display: none;
line-height: 20px;
}
.bar-menu .section a {
color: #373737;
text-decoration: none;
white-space: nowrap;
}
.bar-menu .section a:hover {
color: #373737;
text-decoration: none;
white-space: nowrap;
font-weight: bold;
}
.bar-menu .section .active,
.bar-menu .section .active:hover {
color: yellow;
}
.bar-menu .box3 {
}
.bar-menu .box3-hover {
font-weight: bold;
}
|
hier mein inhalt der java-datei:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 | function BarMenu(id) {
this.box1Hover = true;
this.box2Hover = true;
this.box3Hover = true;
this.highlightActive = false;
this.init = function() {
if (!document.getElementById(this.id)) {
alert("Element '"+this.id+"' does not exist in this document. BarMenu cannot be initialized");
return;
}
this.parse(document.getElementById(this.id).childNodes, this.tree, this.id);
this.load();
if (window.attachEvent) {
window.attachEvent("onunload", function(e) { self.save(); });
} else if (window.addEventListener) {
window.addEventListener("unload", function(e) { self.save(); }, false);
}
}
this.parse = function(nodes, tree, id) {
for (var i = 0; i < nodes.length; i++) {
if (nodes[i].nodeType != 1) {
continue;
}
if (nodes[i].className) {
if ("box1" == nodes[i].className.substr(0, 4)) {
nodes[i].id = id + "-" + tree.length;
tree[tree.length] = new Array();
eval('nodes[i].onmouseover = function() { self.box1over("'+nodes[i].id+'"); }');
eval('nodes[i].onmouseout = function() { self.box1out("'+nodes[i].id+'"); }');
eval('nodes[i].onclick = function() { self.box1click("'+nodes[i].id+'"); }');
}
if ("section" == nodes[i].className) {
id = id + "-" + (tree.length - 1);
nodes[i].id = id + "-section";
tree = tree[tree.length - 1];
}
if ("box2" == nodes[i].className.substr(0, 4)) {
nodes[i].id = id + "-" + tree.length;
tree[tree.length] = new Array();
eval('nodes[i].onmouseover = function() { self.box2over("'+nodes[i].id+'", "'+nodes[i].className+'"); }');
eval('nodes[i].onmouseout = function() { self.box2out("'+nodes[i].id+'", "'+nodes[i].className+'"); }');
eval('nodes[i].onclick = function() { self.box2click("'+nodes[i].id+'"); }');
}
if ("box3" == nodes[i].className.substr(0, 4)) {
nodes[i].id = id + "-" + tree.length;
tree[tree.length] = new Array();
eval('nodes[i].onmouseover = function() { self.box3over("'+nodes[i].id+'", "'+nodes[i].className+'"); }');
eval('nodes[i].onmouseout = function() { self.box3out("'+nodes[i].id+'", "'+nodes[i].className+'"); }');
}
}
if (this.highlightActive && nodes[i].tagName && nodes[i].tagName == "A") {
if (document.location.href == nodes[i].href) {
nodes[i].className = (nodes[i].className ? ' active' : 'active')
}
}
if (nodes[i].childNodes) {
this.parse(nodes[i].childNodes, tree, id);
}
}
}
this.box1over = function(id) {
if (!this.box1Hover) return;
if (!document.getElementById(id)) return;
document.getElementById(id).className = (this.id_openbox == id ? "box1-open-hover" : "box1-hover");
}
this.box1out = function(id) {
if (!this.box1Hover) return;
if (!document.getElementById(id)) return;
document.getElementById(id).className = (this.id_openbox == id ? "box1-open" : "box1");
}
this.box1click = function(id) {
if (!document.getElementById(id)) {
return;
}
var id_openbox = this.id_openbox;
if (this.id_openbox) {
if (!document.getElementById(id + "-section")) {
return;
}
this.hide();
if (id_openbox == id) {
if (this.box1hover) {
document.getElementById(id_openbox).className = "box1-hover";
} else {
document.getElementById(id_openbox).className = "box1";
}
} else {
document.getElementById(id_openbox).className = "box1";
}
}
if (id_openbox != id) {
this.show(id);
var className = document.getElementById(id).className;
if ("box1-hover" == className) {
document.getElementById(id).className = "box1-open-hover";
}
if ("box1" == className) {
document.getElementById(id).className = "box1-open";
}
}
}
this.box2over = function(id, className) {
if (!this.box2Hover) return;
if (!document.getElementById(id)) return;
document.getElementById(id).className = (this.id_openbox == id ? "box2-open-hover" : "box2-hover");
}
this.box2out = function(id, className) {
if (!this.box2Hover) return;
if (!document.getElementById(id)) return;
document.getElementById(id).className = (this.id_openbox == id ? "box2-open" : "box2");
}
this.box2click = function(id) {
if (!document.getElementById(id)) {
return;
}
var id_openbox = this.id_openbox;
if (this.id_openbox) {
if (!document.getElementById(id + "-section")) {
return;
}
this.hide();
if (id_openbox == id) {
if (this.box2hover) {
document.getElementById(id_openbox).className = "box2-hover";
} else {
document.getElementById(id_openbox).className = "box2";
}
} else {
document.getElementById(id_openbox).className = "box2";
}
}
if (id_openbox != id) {
this.show(id);
var className = document.getElementById(id).className;
if ("box2-hover" == className) {
document.getElementById(id).className = "box2-open-hover";
}
if ("box2" == className) {
document.getElementById(id).className = "box2-open";
}
}
}
this.box3over = function(id, className) {
if (!this.box3Hover) return;
if (!document.getElementById(id)) return;
document.getElementById(id).className = className + "-hover";
}
this.box3out = function(id, className) {
if (!this.box3Hover) return;
if (!document.getElementById(id)) return;
document.getElementById(id).className = className;
}
this.show = function(id) {
if (document.getElementById(id + "-section")) {
document.getElementById(id + "-section").style.display = "block";
this.id_openbox = id;
}
}
this.hide = function() {
document.getElementById(this.id_openbox + "-section").style.display = "none";
this.id_openbox = "";
}
this.save = function() {
if (this.id_openbox) {
this.cookie.set(this.id, this.id_openbox);
} else {
this.cookie.del(this.id);
}
}
this.load = function() {
var id_openbox = this.cookie.get(this.id);
if (id_openbox) {
this.show(id_openbox);
document.getElementById(id_openbox).className = "box1-open";
}
}
this.load = function() {
var id_openbox = this.cookie.get(this.id);
if (id_openbox) {
this.show(id_openbox);
document.getElementById(id_openbox).className = "box2-open";
}
}
function Cookie() {
this.get = function(name) {
var cookies = document.cookie.split(";");
for (var i = 0; i < cookies.length; i++) {
var a = cookies[i].split("=");
if (a.length == 2) {
a[0] = a[0].trim();
a[1] = a[1].trim();
if (a[0] == name) {
return unescape(a[1]);
}
}
}
return "";
}
this.set = function(name, value) {
document.cookie = name + "=" + escape(value);
}
this.del = function(name) {
document.cookie = name + "=; expires=Thu, 01-Jan-70 00:00:01 GMT";
}
}
var self = this;
this.id = id;
this.tree = new Array();
this.cookie = new Cookie();
this.id_openbox = "";
}
if (typeof String.prototype.trim == "undefined") {
String.prototype.trim = function() {
var s = this.replace(/^\s*/, "");
return s.replace(/\s*$/, "");
}
}
|
das steht im html:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 | <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta http-equiv="Content-Language" content="en">
<title>Bar Menu</title>
<link rel="stylesheet" type="text/css" href="BarMenu.css">
</head>
<body>
<script type="text/javascript" src="BarMenu.js">
</script>
<style type="text/css">
body {
background-color: #e5e5e5;
}
</style>
<table cellspacing="0" cellpadding="0" id="bar-menu1" class="bar-menu" bgcolor="#f5f5f5">
<tr>
<td height="75">
</td>
</tr>
<tr>
<td>
<div class="box1">produktdesign</div>
<div class="section">
<div class="box2">buildings</div>
</div>
<div class="section">
<p><a href="geniax.html">geniax</a></p>
<p><a href="stratos.html">stratos</a></p>
<p><a href="tornado.html">tornado</a></p>
</div>
</td>
</tr>
<tr><td height="2"></td></tr>
<tr>
<td>
<div class="box1">consumerdesign</div>
<!-- <div class="section">
<div class="box2"><a href="geniax.html">geniax</a></div>
<div class="box2"><a href="stratos.html">stratos</a></div>
<div class="box2"><a href="tornado.html">tornado</a></div>
</div> -->
</td>
</tr>
<tr><td height="2"></td></tr>
<tr>
<td>
<div class="box1">interfacedesign</div>
<div class="section">
<div class="box2"><a href="example1.html">E-mail Support</a></div>
</div>
</td>
</tr>
<tr><td height="2" bgcolor="#f5f5f5"></td></tr>
<tr>
<td>
<div class="box1">kommunikationsdesign</div>
<!--<div class="section">
<div class="box2"><a href="geniax.html">geniax</a></div>
<div class="box2"><a href="stratos.html">stratos</a></div>
<div class="box2"><a href="tornado.html">tornado</a></div>
</div> -->
</td>
</tr>
<tr><td height="2"></td></tr>
<tr>
<td>
<div class="box1">strategisches design</div>
<!--<div class="section">
<div class="box2"><img src="images/arrow2.gif" width="14" height="9" alt=""><a href="example1.html">Customer One</a></div>
<div class="box2"><img src="images/arrow2.gif" width="14" height="9" alt=""><a href="example1.html">Customer Two</a></div>
<div class="box2"><img src="images/arrow2.gif" width="14" height="9" alt=""><a href="example1.html">Customer Three</a></div>
<div class="box2"><img src="images/arrow2.gif" width="14" height="9" alt=""><a href="example1.html">Customer Four</a></div>
<div class="box2"><img src="images/arrow2.gif" width="14" height="9" alt=""><a href="example1.html">Customer Five</a></div>
<div class="box2"><img src="images/arrow2.gif" width="14" height="9" alt=""><a href="example1.html">Customer Six</a></div>
<div class="box2"><img src="images/arrow2.gif" width="14" height="9" alt=""><a href="example1.html">Customer Seven</a></div>
</div> -->
</td>
</tr>
<tr><td height="2"></td></tr>
</table>
<script type="text/javascript">
var barMenu1 = new BarMenu('bar-menu1');
barMenu1.init();
</script>
</body>
</html>
|
such mal unter dropdown + suckerfish… dort gibt es Muster, wie es geht.

