• Jetzt anmelden. Es dauert nur 2 Minuten und ist kostenlos!

Menü bei Seitenstart ausklappt

Monarch

Neues Mitglied
Hallo Experten,

ich möchte gerne das ein bestimmter Menüpunkt bei einem Accordion-Menü gleich bei Seitenstart aufgeklappt ist, wie stelle ich das an?

mfg eem monarch ... und vielen Dank im voraus

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="X-UA-Compatible" content="IE=EmulateIE8">
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Unbenannte Seite</title>
<meta name="generator" content="xxxx">
<style type="text/css">
body
{
background-color: #FFFFFF;
color: #000000;
}
</style>
<link rel="stylesheet" href="./Unbenannt2.css" type="text/css">
<script type="text/javascript" src="./jscookmenu.js"></script>
<style type="text/css">
//a:link { text-decoration:none; font-weight:bold; color:#e00000; }
a:visited { text-decoration:none; font-weight:bold; color:#800000; }
//a:hover { text-decoration:none; font-weight:bold; background-color:#ff0; }
//a:active { text-decoration:none; font-weight:bold; background-color:#cff; }
//a:focus { text-decoration:none; font-weight:bold; background-color:#080; }
</style>

<script type="text/javascript" language="javascript" src="jquery.js"></script>
<script type="text/javascript">
<!--//---------------------------------+
// Developed by Roshan Bhattarai
// Visit http://roshanbh.com.np for this script and more.
// This notice MUST stay intact for legal use
// --------------------------------->
$(document).ready(function()
{
//slides the element with class "menu_body" when paragraph with class "menu_head" is clicked

$("#firstpane p.menu_head").click(function()
{
$(this).siblings("div.menu_bodyx").slideUp("slow");
$(this).siblings("div.menu_body").slideUp("slow");
$(this).css({backgroundImage:"url(down.png)"}).next("div.menu_body").slideToggle(300);
$(this).css({backgroundImage:"url(down.png)"}).next("div.menu_bodyx").slideToggle(300);
$(this).siblings().css({backgroundImage:"url(left.png)"});

});
});
</script>
<style type="text/css">
body {
margin: 10px auto;
font: 75%/120% Verdana,Arial, Helvetica, sans-serif;
}
.menu_list {
width: 150px;
}
.menu_head {
padding: 5px 10px;
cursor: pointer;
position: relative;
margin:1px;
font-weight:bold;

background: #eef4d3 url(left.png) center right no-repeat;
}

.menu_body {
display:none;
}
.menu_body a{
display:block;
background-color:#EFEFEF;
color:#006699;
padding-left:10px;
font-weight:bold;
text-decoration:none;
}
.menu_body a:hover{
color: #000000;
text-decoration:none;
}
</style>

</head>
<body>
<div style="float:left" > <!--This is the first division of left-->

<div id="firstpane" class="menu_list"> <!--Code for menu starts here-->
<div class="menu_head">
<a href="index.html">HEADERTEST</a>
</div>
<p class="menu_head">Hxeader-2</p>
<div class="menu_body">
<a style="background-color:#EF0000",href="#">Link-1</a>
<a href="#">Link-2</a>
<a href="#">Link-3</a>
</div>
<p class="menu_head">TEST</p>
<div class="menu_body">
<a href="#">TEST-1</a>
<a href="#">TEST-2</a>
<a href="#">TEST-3</a>
</div>
<p class="menu_head">Header-3</p>
<div class="menu_body">
<a href="#">Link-1</a>
<a href="#">Link-2</a>
<a href="#">Link-3</a>
</div>
</div> <!--Code for menu ends here-->
</div>

</body>
</html>
 
Um dir dabei zu helfen, wäre ein Link zur Seite wichtig. Nur mit diesem Code kann man das nicht wirklich.
 
Zurück
Oben