[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4688: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3823)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4690: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3823)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4691: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3823)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4692: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3823)
Webmasterplein.net • Toon onderwerp - krijg het menu niet voor elkaar
aan alle goede dingen komt een eind, webmasterplein.net 2003 - 2013
wij danken jullie voor al mooie momenten die dankzij dit forum ontstonden - Derk, Rutger en Stef

krijg het menu niet voor elkaar

Het echte opmaakwerk, alles vragen over HTMLen, CSSen en Javascripten.

krijg het menu niet voor elkaar

Berichtdoor wilma » 03 mei 2006 09:55

Hier ben ik weer eens met een vraag.
Ik ben een nieuwe website aan het maken en wil gebruik maken van een menu waar ik dus niet uitkom. Hoofdpijn krijg ik ervan :ja:
Nu kan ik wel een ander menu zoeken maar ik wil en moet deze. Razz

Als je op home klikt krijg je 2 onderwerpen te zien en het klikdingest klopt niet.
Wie o wie kan mij een blije dag bezorgen?

http://home.quicknet.nl/qn/prive/db.denhelder/index.htm

<html>

<head><style type="text/css">
.menutitle{
cursor:pointer;
margin-bottom: 4px;
background-color:#CC9900;
color:#FFFFFF;
width:160px;
padding:2px;
text-align:center;
font-weight:bold;
/*/*/border:1px solid #FFFFFF;/* */
}

.submenu{
margin-bottom: 0.5em;
}
</style>

<script type="text/javascript">

if (document.getElementById){
document.write('<style type="text/css">\n')
document.write('.submenu{display: none;}\n')
document.write('</style>\n')
}

function SwitchMenu(obj){
if(document.getElementById){
var el = document.getElementById(obj);
var ar = document.getElementById("masterdiv").getElementsByTagName("span");
if(el.style.display != "block"){
for (var i=0; i<ar.length; i++){
if (ar[i].className=="submenu")
ar[i].style.display = "none";
}
el.style.display = "block";
}else{
el.style.display = "none";
}
}
}

</script>

<meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
<title>Javascripts</title>
</head>

<body bgcolor="#CC9900" link="#000000" vlink="#000000" alink="#000000">

<table border="0" cellpadding="0" cellspacing="0" width="856" height="968">
<!-- MSTableType="layout" -->
<tr>
<td valign="top">
<!-- MSCellType="DecArea" -->
&nbsp; <img border="0" src="tekens3.gif" width="61" height="106"></td>
<td>&nbsp;</td>
<td></td>
<td valign="top" rowspan="2">
<!-- MSCellType="ContentHead" -->
&nbsp;</td>
<td valign="top" rowspan="2">
<img border="0" src="!cid_00b401c66b19$cdb39290$6501a8c0@WILMA.gif" width="562" height="72"></td>
<td height="115">&nbsp;</td>
</tr>
<tr>
<td></td>
<td></td>
<td></td>
<td height="1"></td>
</tr>
<tr>
<td></td>
<td></td>
<td></td>
<td></td>
<td></td>
<td height="1"></td>
</tr>
<tr>
<td valign="top" width="160" rowspan="2">
<!-- MSCellType="NavBody" -->
<div id="masterdiv">

<div class="menutitle" onclick="SwitchMenu('sub1')"><font color="#000000">
Home</font></div>
<span class="submenu" id="sub1">
- <a target="_self" href="index.htm">Logo</a><br>
- <a target="_self" href="gastheer.htm">Uw gastheer</a></span><div class="menutitle" onclick="SwitchMenu('sub2')"><font color="#000000">
Over H &amp; O</font></div>
<span class="submenu" id="sub2">
-
<a target="_blank" href="http://home.quicknet.nl/qn/prive/hj.vermeer/index2.htm">
Kattengroep Pashit Cadez</a><br>
- <a target="_blank" href="http://www.de-leguaan.nl/">Terrariumgroep De
Legun </a>
</span>
<div class="menutitle" onclick="SwitchMenu('sub3')"><font color="#000000">
Tentoonstellingen</font></div>
<span class="submenu" id="sub3">
- <a href="../pagina_alerts.htm"><font color="#000000">Alerts</font></a><br>
&nbsp;</span><div class="menutitle" onclick="SwitchMenu('sub4')"><font color="#000000">
Agenda</font></div>
<span class="submenu" id="sub4">
- <a href="../pagina_alerts.htm"><font color="#000000">Alerts</font></a><br>
&nbsp;</span><div class="menutitle" onclick="SwitchMenu('sub5')"><font color="#000000">
Nieuws</font></div>
<span class="submenu" id="sub5">
- <a href="../../pagina_tools_metatag.htm"><font color="#000000">META TAG Generator</font></a><br>
&nbsp;</span><div class="menutitle" onclick="SwitchMenu('sub6')"><font color="#000000">
Links</font></div>
<span class="submenu" id="sub6">
-
<a target="_blank" href="http://home.quicknet.nl/qn/prive/hj.vermeer/index2.htm">
Kattengroep Pashit Cadiz</a><br>
- <a target="_blank" href="http://www.de-leguaan.nl/index.htm">
terrariumgroep De Leguaan</a></span><div class="menutitle" onclick="SwitchMenu('sub7')"><font color="#000000">
Foto's</font></div>
<span class="submenu" id="sub7">
- <a target="_self" href="klusteam.htm">klusteam</a><br>
&nbsp;</span><div class="menutitle" onclick="SwitchMenu('sub8')">
<font color="#000000">Contact</font></div>
<span class="submenu" id="sub8">
<a href="mailto:t.hof1@quicknet.nl?subject=Kleindier-Sportvereniging">-
E-mail Teun</a><br>
<a href="mailto:a.craane@quicknet.nl?subject=kleindier-Sportvereniging H & O">
- E-Mail Aad</a><br>
<a href="mailto:wilmavandijk@quicknet.nl?subject=kleindier-Sportvereniging">
- E-mail Wilma</a><br>
- <a target="_blank" href="http://www.kattenboet.nl"><font color="#000000">Site van de week</font></a><br>
- <a href="../../pagina_contact.htm"><font color="#000000">Gastenboek</font></a>
</span>

</div>
</td>
<td></td>
<td width="3"></td>
<td width="4"></td>
<td width="580"></td>
<td height="2"></td>
</tr>
<tr>
<td width="15" bgcolor="#FFCC00">&nbsp;</td>
<td valign="top" bgcolor="#FFCC00" colspan="3">
<!-- MSCellType="ContentBody" -->
<p align="left">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;
<img border="0" src="Logo%202kl.jpg" width="558" height="488"><br>
<font size="4" face="Arial">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </font></td>
<td height="851" width="94" valign="top">
&nbsp;</td>
</tr>
</table>
<STYLE type="text/css">
<!--
BODY {
scrollbar-face-color:FFCC00 ;
scrollbar-arrow-color:FF9900 ;
}
-->
</STYLE>

</body>

</html>
wilma
wmpr
 
Berichten: 238
Geregistreerd: 28 nov 2003 15:37
Woonplaats: Den Helder

Re: krijg het menu niet voor elkaar

Berichtdoor KillerSponge » 03 mei 2006 10:51

Ik weet het niet zeker, maar ik vermoed dat het te maken heeft met het feit dat de 2 linkjess in die kolom staan, op een aparte regel. Javascript kan daar niet altijd mee omgaan. Probeer de linkjes eens op dezelfde regel te zetten (maar dan wel gewoon met een <br> er tussen).
Blabla en andere onzin - http://killersponge.nl
Avatar gebruiker
KillerSponge
Beheerder
Beheerder
 
Berichten: 14456
Geregistreerd: 24 aug 2004 13:05

Re: krijg het menu niet voor elkaar

Berichtdoor wilma » 03 mei 2006 11:24

Helaas ... dit veranderd er niets aan
wilma
wmpr
 
Berichten: 238
Geregistreerd: 28 nov 2003 15:37
Woonplaats: Den Helder

Re: krijg het menu niet voor elkaar

Berichtdoor Anthony » 03 mei 2006 12:54

Avatar gebruiker
Anthony
wmpr
 
Berichten: 2828
Geregistreerd: 07 aug 2004 14:05
Woonplaats: Brugge - Belgiƫ

Re: krijg het menu niet voor elkaar

Berichtdoor wilma » 03 mei 2006 15:13

wilma
wmpr
 
Berichten: 238
Geregistreerd: 28 nov 2003 15:37
Woonplaats: Den Helder

Re: krijg het menu niet voor elkaar

Berichtdoor Anthony » 03 mei 2006 15:44

Avatar gebruiker
Anthony
wmpr
 
Berichten: 2828
Geregistreerd: 07 aug 2004 14:05
Woonplaats: Brugge - Belgiƫ

Re: krijg het menu niet voor elkaar

Berichtdoor wilma » 03 mei 2006 16:33

wilma
wmpr
 
Berichten: 238
Geregistreerd: 28 nov 2003 15:37
Woonplaats: Den Helder

Re: krijg het menu niet voor elkaar

Berichtdoor Weeeyaa » 03 mei 2006 17:36

Avatar gebruiker
Weeeyaa
wmpr
 
Berichten: 2796
Geregistreerd: 10 jul 2004 07:39

Re: krijg het menu niet voor elkaar

Berichtdoor wilma » 04 mei 2006 09:27

wilma
wmpr
 
Berichten: 238
Geregistreerd: 28 nov 2003 15:37
Woonplaats: Den Helder

Re: krijg het menu niet voor elkaar

Berichtdoor KillerSponge » 04 mei 2006 09:31

Kan, maar het is simpeler op deze manier:

[code="html"]<div style="margin-top: 10;">-- Hier het script voor het menu -- </div> [/code]
Blabla en andere onzin - http://killersponge.nl
Avatar gebruiker
KillerSponge
Beheerder
Beheerder
 
Berichten: 14456
Geregistreerd: 24 aug 2004 13:05

Re: krijg het menu niet voor elkaar

Berichtdoor wilma » 04 mei 2006 11:14

ik ben nu dus al vanaf 11 uur bezig, maar ik snap er helemaal niets meer van.
Hoe kunnen jullie dat geduld opbrengen!
Mag ik vragen om nog een poging om het mij uit te leggen? Embarassed
wilma
wmpr
 
Berichten: 238
Geregistreerd: 28 nov 2003 15:37
Woonplaats: Den Helder

Re: krijg het menu niet voor elkaar

Berichtdoor KillerSponge » 04 mei 2006 11:21

Ik denk dat je te moeilijk denkt ^^

Kun je misschien de bron die je nu hebt posten?
Blabla en andere onzin - http://killersponge.nl
Avatar gebruiker
KillerSponge
Beheerder
Beheerder
 
Berichten: 14456
Geregistreerd: 24 aug 2004 13:05

Re: krijg het menu niet voor elkaar

Berichtdoor wilma » 04 mei 2006 11:28

ik hoop dat je met de bron onderstaande bedoelt?

<html>

<head><style type="text/css">
DIV.clSlide{position:absolute; ;z-index:10; left:0; width:138; height:22; clip:rect(0,138,22,0); padding:3px;}
DIV.clSlideSub{position:absolute; ;z-index:10; padding:2px; clip:rect(0,127,20,0); width:127; height:20; left:8; visibility:hidden}
DIV.clSlideSub2{position:absolute; ;z-index:10; padding:2px; clip:rect(0,118,20,0); width:118; height:20; left:8; visibility:hidden}
#divSlideCont{position:absolute; z-index:10; left:0; top:100; height:600; width:170; visibility:hidden}
A.clSlideLinks{font-family:Verdana, Helvetica, Helv; font-size:11px; font-weight:bold; text-decoration:none; color:white}
A.clSlideSubLinks{font-family:Verdana, Helvetica, Helv; font-size:10px; text-decoration:none; color:Navy}
A.clSlideSub2Links{font-family:Verdana, Helvetica, Helv; font-size:9px; text-decoration:none; color:Navy}
</style>


<script language="JavaScript" type="text/javascript">
/**********************************************************************************
SlideMenu
* Copyright (C) 2001 Thomas Brattli
* This script was released at DHTMLCentral.com
* Visit for more great scripts!
* This may be used and changed freely as long as this msg is intact!
* We will also appreciate any links you could give us.
*
* Made by Thomas Brattli
*
* Script date: 08/01/2002 (keep this date to check versions)
*********************************************************************************/
function lib_bwcheck(){ //Browsercheck (needed)
this.ver=navigator.appVersion
this.agent=navigator.userAgent
this.dom=document.getElementById?1:0
this.opera5=(navigator.userAgent.indexOf("Opera")>-1 && document.getElementById)?1:0
this.ie5=(this.ver.indexOf("MSIE 5")>-1 && this.dom && !this.opera5)?1:0;
this.ie6=(this.ver.indexOf("MSIE 6")>-1 && this.dom && !this.opera5)?1:0;
this.ie4=(document.all && !this.dom && !this.opera5)?1:0;
this.ie=this.ie4||this.ie5||this.ie6
this.mac=this.agent.indexOf("Mac")>-1
this.ns6=(this.dom && parseInt(this.ver) >= 5) ?1:0;
this.ns4=(document.layers && !this.dom)?1:0;
this.bw=(this.ie6 || this.ie5 || this.ie4 || this.ns4 || this.ns6 || this.opera5)
return this
}
var bw=lib_bwcheck()
//Opera didn't seem to like the padding in the layers, it messes up the background-images, so here's a version without it.
if(bw.opera5) document.write("<style>DIV.clSlide{padding:0px; background-image:url(' ')}\nDIV.clSlideSub{padding:0px; background-image:url(' ')}\nDIV.clSlideSub2{padding:0px; background-image:url(' ')}</style>")

/************************************************************************************
Making cross-browser objects
************************************************************************************/
function makeMenuObj(obj,nest){
nest=(!nest) ? "":'document.'+nest+'.'
this.css=bw.dom? document.getElementById(obj).style:bw.ie4?document.all[obj].style:bw.ns4?eval(nest+"document.layers." +obj):0;
this.el=bw.dom?document.getElementById(obj):bw.ie4?document.all[obj]:bw.ns4?eval(nest+'document.'+obj):0;
this.ref=bw.dom || bw.ie4? document:bw.ns4?eval(nest+"document.layers." +obj+".document"):0;
this.x=(bw.ns4 || bw.ns5)? this.css.left:this.css.offsetLeft;
this.y=(bw.ns4 || bw.ns5)? this.css.top:this.css.offsetTop;
this.hideIt=b_hideIt; this.showIt=b_showIt; this.movey=b_movey
this.moveIt=b_moveIt; this.moveBy=b_moveBy; this.status=0;
this.bgImg=b_bgImg; this.obj = obj + "Object"; eval(this.obj + "=this");
this.clipTo=b_clipTo;
return this
}
function b_showIt(){this.css.visibility="visible"; this.status=1}
function b_hideIt(){this.css.visibility="hidden"; this.status=0}
function b_movey(y){this.y=y; this.css.top=this.y}
function b_moveIt(x,y){this.x=x; this.y=y; this.css.left=this.x;this.css.top=this.y}
function b_moveBy(x,y){this.x=this.x+x; this.y=this.y+y; this.css.left=this.x;this.css.top=this.y}
function b_bgImg(img){if(bw.ie||bw.dom)this.css.backgroundImage="url("+img+")"
else this.css.background.src=img
}
function b_clipTo(t,r,b,l,w){if(bw.ns4){this.css.clip.top=t;this.css.clip.right=r
this.css.clip.bottom=b;this.css.clip.left=l
}else{this.css.clip="rect("+t+","+r+","+b+","+l+")"; if(w){this.css.width=r; this.css.height=b}}}
/********************************************************************************
Initiating page, making objects..
********************************************************************************/
function SlideMenuInit(){
oSlideMenu=new makeMenuObj('divSlideCont')
oSlideMenu.moveIt(menux,menuy)
oSlide=new Array()
for(i=0;i<menus.length;i++){
oSlide[i]=new makeMenuObj('divSlide'+i,'divSlideCont')
oSlide[i].subs=menus[i].subs
oSlide[i].sub=new Array()
oSlide[i].moveIt(0,mainheight*i)
oSlide[i].starty=oSlide[i].y
if(bw.opera) oSlide[i].css.paddingLeft="10px"
if(!menus[i].seperator) oSlide[i].bgImg(level0_regular)
for(j=0;j<oSlide[i].subs;j++){
oSlide[i].sub[j]=new makeMenuObj('divSlideSub'+i+"_"+j,'divSlideCont')
oSlide[i].sub[j].moveIt(10,oSlide[i].y+subheight*j+between)
oSlide[i].sub[j].starty=oSlide[i].sub[j].y
oSlide[i][j]=new Array()
oSlide[i][j].subs=menus[i][j].subs
oSlide[i][j].sub=new Array()
img=level1_round
if(oSlide[i][j].subs!=0){
if(j!=oSlide[i].subs-1) img=level1_sub
else img=level1_sub_round
oSlide[i].sub[j].css.color="white"
}else{
if(j!=oSlide[i].subs-1)img=level1_regular
}
oSlide[i].sub[j].origimg=img
oSlide[i].sub[j].bgImg(img)
for(a=0;a<oSlide[i][j].subs;a++){
oSlide[i][j].sub[a]=new makeMenuObj('divSlideSub'+i+"_"+j+"_"+a,'divSlideCont')
oSlide[i][j].sub[a].moveIt(20,oSlide[i].sub[j].y+subheight*a+between-2)
oSlide[i][j].sub[a].starty=oSlide[i][j].sub[a].y
oSlide[i][j][a]=new Array()
oSlide[i][j][a].subs=menus[i][j][a].subs
oSlide[i][j][a].sub=new Array()
if(a!=oSlide[i][j].subs-1) img=level2_regular
else img=level2_round
oSlide[i][j].sub[a].origimg=img
oSlide[i][j].sub[a].bgImg(img)
}
}
}
oSlideMenu.showIt()
}
/********************************************************************************
Variables
********************************************************************************/
var active=-1;var going;var isthere; var sactive=-1; var sisthere=-1; var s2active=-1; var s2isthere=-1
/********************************************************************************
Switch menu function.
********************************************************************************/
function swmenu(num,snum,s2num){
if(snum!=-1){
if(oSlide[num][snum].subs==0) return
}
if(s2num!=-1){
if(oSlide[num][snum][s2num].subs==0) return
}
if((num!=active || snum!=sactive || s2num!=s2active) && !going){going=true;isthere=0;sisthere=0;moveUp(num,snum,s2num)}
}
/********************************************************************************
Moving the menus upward to their original position.
********************************************************************************/
function moveUp(num,snum){
if(snum==-1){
for(i=0;i<oSlide.length;i++){
if(oSlide[i].y>oSlide[i].starty+pxspeed && active!=i) oSlide[i].moveBy(0,-pxspeed)
else{if(active!=i) oSlide[i].moveIt(oSlide[i].x,oSlide[i].starty); isthere=i}
}

if(isthere<oSlide.length-1) setTimeout("moveUp("+num+","+snum+")",timspeed)
else swmenu2(num,snum)
}else{
if(num==oSlide.length-1) isthere=num

if(sactive!=-1){ //Is out!
//Slide subs
j=0
for(i=sactive+1;i<oSlide[num].sub.length;i++){
j++
if(oSlide[num].sub[i].y>oSlide[num].sub[i].starty+pxspeed) oSlide[num].sub[i].moveBy(0,-pxspeed)
else{oSlide[num].sub[i].moveIt(oSlide[num].sub[i].x,oSlide[num].sub[i].starty); sisthere=i}
}
//Slide main
for(i=num+1;i<oSlide.length;i++){
if(oSlide[i].y>oSlide[i].starty + oSlide[num].sub[sactive].y +subheight*j ) oSlide[i].moveBy(0,-pxspeed)
else{oSlide[i].moveIt(oSlide[i].x,oSlide[i].starty + oSlide[num].sub[sactive].y +subheight*j ); isthere=i}
}
}else{ //Slide to the one clicked
for(i=num+1;i<oSlide.length;i++){
if(oSlide[i].y>oSlide[i].starty + snum*between+between) oSlide[i].moveBy(0,-pxspeed)
else{oSlide[i].moveIt(oSlide[i].x,oSlide[i].starty + snum*between+between); isthere=i}
}
}
if(isthere<oSlide.length-1 || (sactive!=-1 && sisthere<oSlide[num].sub.length-1 && sactive!=oSlide[num].sub.length-1)) setTimeout("moveUp("+num+","+snum+")",timspeed)
else swmenu2(num,snum)
}
}
/********************************************************************************
Switch menu 2, stuff that happens before the menus are moved down again.
********************************************************************************/
function swmenu2(num,snum){
isthere=0;
sisthere=0;
if(active>-1 && snum==-1){
//Hiding submenus
for(j=0;j<oSlide[active].subs;j++){oSlide[active].sub[j].hideIt()}
oSlide[active].bgImg(level0_regular)
oSlide[active].moveIt(0,oSlide[active].starty)
}
if(sactive>-1){
//Hiding submenus
for(j=0;j<oSlide[active][sactive].sub.length;j++){oSlide[active][sactive].sub[j].hideIt()}
oSlide[active].sub[sactive].bgImg(oSlide[active].sub[sactive].origimg)
oSlide[active].sub[sactive].moveIt(10,oSlide[active].sub[sactive].starty)
//Move back to place
for(i=sactive+1;i<oSlide[active].sub.length;i++){
oSlide[active].sub[i].moveIt(oSlide[active].sub[i].x,oSlide[active].sub[i].starty)
}
}
active=num
//Showing submenus
if(snum>-1){
sactive=snum
for(j=0;j<oSlide[num][snum].sub.length;j++){oSlide[num][snum].sub[j].showIt()}
oSlide[num].sub[snum].moveBy(10,3)
oSlide[num].sub[snum].bgImg(level1_round2)
}else{
sactive=-1
for(j=0;j<oSlide[active].subs;j++){oSlide[active].sub[j].showIt()}
oSlide[num].moveBy(10,3)
oSlide[num].bgImg(level0_round)
}
if(num!=oSlide.length-1) moveDown(num,snum)
else{
isthere=num
moveDown(num,snum)
}
}
/********************************************************************************
Moving the menus down
********************************************************************************/
function moveDown(num,snum){
//if(num==oSlide.length-1) isthere=num
for(i=num+1;i<oSlide.length;i++){
if(snum==-1){
if(oSlide[i].y<(oSlide[num].subs-1)*subheight+oSlide[i].starty+between-pxspeed) oSlide[i].moveBy(0,pxspeed)
else{oSlide[i].moveIt(oSlide[i].x,(oSlide[num].subs-1)*subheight+oSlide[i].starty+between); isthere=i}
}else{
if(oSlide[i].y<(oSlide[num].subs-1)*subheight+oSlide[i].starty+between-pxspeed + (oSlide[num][snum].subs-1)*subheight+between) oSlide[i].moveBy(0,pxspeed)
else{oSlide[i].moveIt(oSlide[i].x,(oSlide[num].subs-1)*subheight+oSlide[i].starty+between + (oSlide[num][snum].subs-1)*subheight+between); isthere=i}
}
}
if(snum!=-1){
for(i=snum+1;i<oSlide[num].sub.length;i++){
if(oSlide[num].sub[i].y<(oSlide[num][snum].subs-1)*subheight+oSlide[num].sub[i].starty+between-pxspeed) oSlide[num].sub[i].moveBy(0,pxspeed)
else{oSlide[num].sub[i].moveIt(oSlide[num].sub[i].x,(oSlide[num][snum].subs-1)*subheight+oSlide[num].sub[i].starty+between); sisthere=i}
}
}
if(snum==-1){
if(isthere<oSlide.length-1) setTimeout("moveDown("+num+","+snum+")",timspeed)
else going=false
}else{
if(isthere<oSlide.length-1 || (sisthere<oSlide[num].sub.length-1 && snum!=oSlide[num].sub.length-1)) setTimeout("moveDown("+num+","+snum+")",timspeed)
else going=false
}
}
var test=0
/********************************************************************************
Functions to write out the layers...
********************************************************************************/
menus=new Array(); var a=0; var b=0; var c=0; var d=0
function makeMenu(type,text,lnk,target,end){
str=""; tg="";
if(target) tg='target="'+target+'"'
if(!lnk) lnk="#"
self.status=lnk
if(a==0) str='<div id="divSlideCont">\n'
if(type=="top"){
menus[a]=new Array();
if(text=="seperator"){
str+='\t<div id="divSlide'+a+'" class="clSlide"></div>\n'
menus[a].seperator=1
}else{
str+='\t<div id="divSlide'+a+'" class="clSlide"><a href="'+lnk+'" '+tg+' onclick="swmenu('+a+',-1,-1); if(bw.ie || bw.ns6) this.blur(); '
if(lnk=="#") str+='return false'
str+='" class="clSlideLinks"> '+text+'</a><br></div>\n'
}
menus[a].subs=0; a++; b=0
}else if(type=="sub"){
str+='\t\t<div id="divSlideSub'+(a-1)+'_'+(b)+'" class="clSlideSub"><a '+tg+' onclick="swmenu('+(a-1)+','+b+',-1); if(bw.ie || bw.ns6) this.blur(); '
if(lnk=="#") str+='return false'
str+='" href="'+lnk+'" class="clSlideSubLinks"> '+text+'</a><br></div>\n'
b++; menus[a-1].subs=b; menus[a-1][b-1]=new Array(); c=0; menus[a-1][b-1].subs=0
}else if(type=="sub2"){
str+='\t\t<div id="divSlideSub'+(a-1)+'_'+(b-1)+'_'+c+'" class="clSlideSub2"><a '+tg+' href="'+lnk+'" class="clSlideSub2Links"> '+text+'</a><br></div>\n'
c++; menus[a-1][b-1].subs=c; menus[a-1][b-1][c-1]=new Array(); d=0; menus[a-1][b-1][c-1].subs=0
}
if(end) str+="</div>"
document.write(str)
}
function preLoadBackgrounds(){
for(i=0;i<arguments.length;i++){
this[i]=new Image()
this[i].src=arguments[i]
}
return this
}
</script>
<style type="text/css">
.menutitle{
cursor:pointer;
margin-bottom: 4px;
background-color:#CC9900;
color:#FFFFFF;
width:160px;
padding:2px;
text-align:center;
font-weight:bold;
/*/*/border:1px solid #FFFFFF;/* */
}

.submenu{
margin-bottom: 0.5em;
}
</style>

<script type="text/javascript">

if (document.getElementById){
document.write('<style type="text/css">\n')
document.write('.submenu{display: none;}\n')
document.write('</style>\n')
}

function SwitchMenu(obj){
if(document.getElementById){
var el = document.getElementById(obj);
var ar = document.getElementById("masterdiv").getElementsByTagName("span");
if(el.style.display != "block"){
for (var i=0; i<ar.length; i++){
if (ar[i].className=="submenu")
ar[i].style.display = "none";
}
el.style.display = "block";
}else{
el.style.display = "none";
}
}
}

</script>

<meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
<title>Javascripts</title>
</head>

<body bgcolor="#CC9900" link="#000000" vlink="#000000">

<table border="0" cellpadding="0" cellspacing="0" width="856" height="968">
<!-- MSTableType="layout" -->
<tr>
<td valign="top">
<!-- MSCellType="DecArea" -->
&nbsp; <img border="0" src="vog-26.gif" width="94" height="125"></td>
<td>&nbsp;</td>
<td></td>
<td valign="top" rowspan="2">
<!-- MSCellType="ContentHead" -->
&nbsp;</td>
<td valign="top" rowspan="2">
<img border="0" src="logo%20goed.gif" width="562" height="72"><p>&nbsp;</td>
<td height="115">&nbsp;</td>
</tr>
<tr>
<td></td>
<td></td>
<td></td>
<td height="1"></td>
</tr>
<tr>
<td></td>
<td></td>
<td></td>
<td></td>
<td></td>
<td height="1"></td>
</tr>
<tr>
<td valign="top" width="160" rowspan="2">
<!-- MSCellType="NavBody" -->
<div id="masterdiv">


<p>&nbsp;<script>

//Variables to set
between=28 //The pixel between the menus and the submenus
mainheight=25 //The height of the mainmenus
subheight=22 //The height of the submenus
pxspeed=13 //The pixel speed of the animation
timspeed=15 //The timer speed of the animation
menuy=80 //The top placement of the menu.
menux=0 //The left placement of the menu
//Images - Play with these
level0_regular="level0_regular.gif"
level0_round="level0_round.gif"
level1_regular="level1_regular.gif"
level1_round="level1_round.gif"
level1_sub="level1_sub.gif"
level1_sub_round="level1_sub_round.gif"
level1_round2="level1_round2.gif"
level2_regular="level2_regular.gif"
level2_round="level2_round.gif"

//Leave this line
preLoadBackgrounds(level0_regular,level0_round,level1_regular,level1_round,level1_sub,level1_sub_round,level1_round2,level2_regular,level2_round)


//There are 3 different types of menus you can make
//top = Main menus
//sub = Sub menus
//sub2 = SubSub menus

//You control the look of the menus in the stylesheet

//makeMenu('TYPE','TEXT','LINK','TARGET', 'END (THE LAST MENU)')

//Menu 0
makeMenu('top','News')
makeMenu('sub','Newest news','/news/index.asp')
makeMenu('sub','News archive','/news/archive.asp')

//Menu 1
makeMenu('top','Scripts')
makeMenu('sub','New scripts','/script/search.asp?new=1')
makeMenu('sub','All scripts','/script/index.asp')
makeMenu('sub','Categories')
makeMenu('sub2','Menu scripts','/script/search.asp?category=menu')
makeMenu('sub2','Text scripts','/script/search.asp?category=text')
makeMenu('sub2','Animation scripts','/script/search.asp?category=animation')
makeMenu('sub2','Other scripts','/script/search.asp?category=other')

//Menu 2
makeMenu('top','Tutorials')
makeMenu('sub','Tutorials','/tutorials/index.asp')
//Menu 3
makeMenu('top','Forums')
makeMenu('sub','Cool sites','forums/forum.asp?FORUM_ID=1&CAT_ID=1&Forum_Title=Cool+sites')
makeMenu('sub','CoolMenus','forums/forum.asp?FORUM_ID=2&CAT_ID=1&Forum_Title=CoolMenus')
makeMenu('sub','Crossbrowser','forums/forum.asp?FORUM_ID=3&CAT_ID=1&Forum_Title=Crossbrowser+DHTML')
makeMenu('sub','Scripts','forums/forum.asp?FORUM_ID=4&CAT_ID=1&Forum_Title=DHTML+Scripts')
makeMenu('sub','dhtmlcentral.com','forums/forum.asp?FORUM_ID=5&CAT_ID=1&Forum_Title=dhtmlcentral%2Ecom')
makeMenu('sub','General','forums/forum.asp?FORUM_ID=6&CAT_ID=1&Forum_Title=General+DHTML+issues')
makeMenu('sub','Off-topic','forums/forum.asp?FORUM_ID=9&CAT_ID=1&Forum_Title=Off%2Dtopic')
makeMenu('sub','Active topics','forums/active.asp')

//Menu 4
makeMenu('top','CoolMenus')
makeMenu('sub','Examples','coolmenus/examples/')
makeMenu('sub','Download','coolmenus/download.asp')
makeMenu('sub','Tutorial','coolmenus/tutorial.asp')
makeMenu('sub','FAQ','faq/index.asp')

//Menu 5
makeMenu('top','Resources')
makeMenu('sub','DHTML Links','resources/default.asp')

//Menu 6
makeMenu('top','dhtmlcentral')
makeMenu('sub','dhtmlcentral','dhtmlcentral/index.asp',"",1)

//Starting the menu
onload=SlideMenuInit;
</script>
<td></td>
<td width="3"></td>
<td width="4"></td>
<td width="580"></td>
<td height="2"></td>
</tr>
<tr>
<td width="15" bgcolor="#FFCC00">&nbsp;</td>
<td valign="top" bgcolor="#FFCC00" colspan="3">
<!-- MSCellType="ContentBody" -->
<p align="left">&nbsp;<br>
<font size="4" face="Arial">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </font></td>
<td height="851" width="94" valign="top">
&nbsp;</td>
</tr>
</table>
<STYLE type="text/css">
<!--
BODY {
scrollbar-face-color:FFCC00 ;
scrollbar-arrow-color:FF9900 ;
}
-->
</STYLE>

</body>

</html>
wilma
wmpr
 
Berichten: 238
Geregistreerd: 28 nov 2003 15:37
Woonplaats: Den Helder

Re: krijg het menu niet voor elkaar

Berichtdoor KillerSponge » 04 mei 2006 11:52

Ik heb het script nog ff doorgenomen, en er zit heel netjes een variabele ingebouwd die je kan aanpassen voor de hoogte Smile

Zoek maar eens op dit regeltje in de bron:

[code="javascript"]menuy=80 //The top placement of the menu.[/code]

Als je die waarde van 80 in bv. 150 veranderd, gaat hij een stuk naar beneden. Op dezelfde manier kan je de waarde menux (eronder) aanpassen voor het x coordinaat van het menu Smile
Blabla en andere onzin - http://killersponge.nl
Avatar gebruiker
KillerSponge
Beheerder
Beheerder
 
Berichten: 14456
Geregistreerd: 24 aug 2004 13:05

Re: krijg het menu niet voor elkaar

Berichtdoor wilma » 04 mei 2006 12:05

pffff, gelukt! Very Happy
Je kan je niet voorstellen hoe blij ik hier mee ben!
Hartstikke bedankt! :kiss:

groetjes,
Wilma
wilma
wmpr
 
Berichten: 238
Geregistreerd: 28 nov 2003 15:37
Woonplaats: Den Helder


Keer terug naar HTML, CSS, Javascript



cron