Back To Start Of Archive
Taken From The Forum: Help & Support for DHTML Menu Version 5+
Forum Topic: Click to view post
Last Updated: Saturday July 14 2012 - 06:07:15
Syntax Error??
Poster: wingrove
Dated: Friday February 3 2006 - 18:32:52 GMT
I have finally been able to add sublevels to the menu, but only as the end of the other level.
What have I done incorrectly, so that the Valentine Strike Item can stand by itself and not grouped with the next Item 'Other'
in action at: http://freepages.family.rootsweb.com/~shurley/
Code:
with(milonic=new menuname("People")){
itemheight=24;
itemwidth=126;
style=submenuStyle;
aI("bgimage=mint_top.gif;status=(aq) Parents;text=Parents;url=parents.htm;");
aI("bgimage=mint_mid.gif;text=Paul Hurley;url=paul.htm;");
aI("bgimage=mint_mid.gif;text=Maureen Hurley;url=maureen.htm;");
aI("bgimage=mint_mid.gif;text=Suzanne Hurley;url=suzanne.htm;");
aI("bgimage=mint_mid.gif;text=Brian Hurley;url=brian.htm;");
aI("bgimage=mint_mid.gif;text=Peter Hurley;url=peter.htm;");
aI("bgimage=mint_bot.gif;showmenu=pf;status=pf;text=Pete's family;");
}
with(milonic=new menuname("pf")){
itemheight=24;
itemwidth=126;
style=submenuStyle;aI("bgimage=mint_mid.gif;text=Valentine Strike;url=strike.htm;");
aI("bgimage=mint_bot.gif;showmenu=op;status=op;text=Others;");
}
with(milonic=new menuname("op")){
itemheight=24;
itemwidth=126;
style=submenuStyle;
aI("bgimage=mint_top.gif;text=- John Hurley;url=john-hurley.htm");
aI("bgimage=mint_bot.gif;text=- Michael Collins;url=collins.htm");
}
itemheight=24;
itemwidth=126;
style=submenuStyle;
aI("bgimage=mint_top.gif;status=(aq) Parents;text=Parents;url=parents.htm;");
aI("bgimage=mint_mid.gif;text=Paul Hurley;url=paul.htm;");
aI("bgimage=mint_mid.gif;text=Maureen Hurley;url=maureen.htm;");
aI("bgimage=mint_mid.gif;text=Suzanne Hurley;url=suzanne.htm;");
aI("bgimage=mint_mid.gif;text=Brian Hurley;url=brian.htm;");
aI("bgimage=mint_mid.gif;text=Peter Hurley;url=peter.htm;");
aI("bgimage=mint_bot.gif;showmenu=pf;status=pf;text=Pete's family;");
}
with(milonic=new menuname("pf")){
itemheight=24;
itemwidth=126;
style=submenuStyle;aI("bgimage=mint_mid.gif;text=Valentine Strike;url=strike.htm;");
aI("bgimage=mint_bot.gif;showmenu=op;status=op;text=Others;");
}
with(milonic=new menuname("op")){
itemheight=24;
itemwidth=126;
style=submenuStyle;
aI("bgimage=mint_top.gif;text=- John Hurley;url=john-hurley.htm");
aI("bgimage=mint_bot.gif;text=- Michael Collins;url=collins.htm");
}
thanks
Poster: Ruth
Dated: Saturday February 4 2006 - 0:11:21 GMT
Hi,
I'm sorry I don't understand the problem. Do you want to add the submenus someplace else? Are you saying that if you try to add a submenu to some item in the middle position of a submenu it won't work? You should be able to add a next level from a sub in any item you want.
Ruth
Poster: wingrove
Dated: Saturday February 4 2006 - 14:09:03 GMT
The problem is how do you end a sublevel listing so that it isn' t part of the next entry in the meu
In the above example
It shoud show as:
Main List
is Parents. htm
paul.htm
maureen.htm
suzane.htm
brian. htm
peter. htm
Pete's family (sub)
............ strike.htm
Other (sub level)
.......... john-hurley.htm
......... colins.htm
As it stands now the Other is attached to the previous Level
-----
Pete's family (sub)
........... strike.htm
Other
.......... john-hurley.htm
......... colins.htm
looking like the last two entries are part of Pete' Family. Which they are not
If the problem solution is Adding the closing '}'
to this line
It causes the menu not to show on FireFox
aI("bgimage=mint_mid.gif;text=Valentine Strike;url=strike.htm;");
So there may be more involved than just than just the bracket
Poster: Ruth
Dated: Saturday February 4 2006 - 17:00:40 GMT
Hi,
The reason that Others is in the pete's family [pf] submenu is because you have put the Others aI in that submenu instead of leaving it as the last item in the People submenu. Try this
Code:
with(milonic=new menuname("People")){
itemheight=24;
itemwidth=126;
style=submenuStyle;
aI("bgimage=mint_top.gif;status=(aq) Parents;text=Parents;url=parents.htm;");
aI("bgimage=mint_mid.gif;text=Paul Hurley;url=paul.htm;");
aI("bgimage=mint_mid.gif;text=Maureen Hurley;url=maureen.htm;");
aI("bgimage=mint_mid.gif;text=Suzanne Hurley;url=suzanne.htm;");
aI("bgimage=mint_mid.gif;text=Brian Hurley;url=brian.htm;");
aI("bgimage=mint_mid.gif;showmenu=pf;status=pf;text=Peter Hurley;url=peter.htm;");
aI("bgimage=mint_bot.gif;showmenu=op;status=op;text=Others;");
}
itemheight=24;
itemwidth=126;
style=submenuStyle;
aI("bgimage=mint_top.gif;status=(aq) Parents;text=Parents;url=parents.htm;");
aI("bgimage=mint_mid.gif;text=Paul Hurley;url=paul.htm;");
aI("bgimage=mint_mid.gif;text=Maureen Hurley;url=maureen.htm;");
aI("bgimage=mint_mid.gif;text=Suzanne Hurley;url=suzanne.htm;");
aI("bgimage=mint_mid.gif;text=Brian Hurley;url=brian.htm;");
aI("bgimage=mint_mid.gif;showmenu=pf;status=pf;text=Peter Hurley;url=peter.htm;");
aI("bgimage=mint_bot.gif;showmenu=op;status=op;text=Others;");
}
That would be the menu that drops from People in the main menu, the last item of that menu would be Others. There would be two submenus coming off that People menu, one would be for Pete's family [pf] and the other would be for Other People [op]
Pete's Family [pf] would be set up like this and use the image posted below. Just right click and copy it. That image is only for a submenu that has just one item in it.
Code:
with(milonic=new menuname("pf")){
itemheight=30;
itemwidth=126;
style=submenuStyle;
aI("bgimage=mint_ful.gif;text=Valentine Strike;url=strike.htm;");
}
itemheight=30;
itemwidth=126;
style=submenuStyle;
aI("bgimage=mint_ful.gif;text=Valentine Strike;url=strike.htm;");
}
The Other people submenu [op] would be just what it is now, I think
Code:
with(milonic=new menuname("op")){
itemheight=24;
itemwidth=126;
style=submenuStyle;
aI("bgimage=mint_top.gif;text=- John Hurley;url=john-hurley.htm");
aI("bgimage=mint_bot.gif;text=- Michael Collins;url=collins.htm");
}
itemheight=24;
itemwidth=126;
style=submenuStyle;
aI("bgimage=mint_top.gif;text=- John Hurley;url=john-hurley.htm");
aI("bgimage=mint_bot.gif;text=- Michael Collins;url=collins.htm");
}
That should give you a main menu with People item, when you mouseover you'll get
Code:
Parents
Paul Hurley
Maureen Hurley
Brian Hurley
Peter Hurley -> mouseover = pf sub [ Valentine Strike ]
Others -> mouseover = op sub [ John Hurley
Michael Collins ]
Paul Hurley
Maureen Hurley
Brian Hurley
Peter Hurley -> mouseover = pf sub [ Valentine Strike ]
Others -> mouseover = op sub [ John Hurley
Michael Collins ]
Ruth
Poster: wingrove
Dated: Saturday February 4 2006 - 17:48:26 GMT
Many thanks Ruth!
Problem not only solved, but you went beyond my question and added an improvement with the inclusion of mint_ful.gif for one item menus.
You are a person of value- solving not only the problem but looking beyond the problem asked! I could use a car mechanic, and a doctor with your qualities