他们要是借鉴 www.opencube.com 上提供的一个例子,我也采用了Www.opercube.com的例子,但是发现到了Http://方式访问的时候,老是出现一个要我注册的信息,但他们的费用有点贵。各位高人,看看有没有什么办法解决这个问题,或者其他地方有免费的能比较漂亮的实现这个功能的东东,我为这个花了不少时间了。本人一定要高分相送,并重新开贴子。
---------------------------------------------------------------
我有一份这菜单,没有出现这个现象,我发给你,给我你的mail先,或说出你的现象。
---------------------------------------------------------------
用fireworks 可以很轻松的做出这样的效果
这是我做的一个,你看看行不行
http://www.sd-youcheng.com
---------------------------------------------------------------
给你代码:
1<script language="JavaScript">
2<!--
3
4function MM_goToURL() { //v3.0
5var i, args=MM_goToURL.arguments; document.MM_returnValue = false;
6for (i=0; i<(args.length-1); i+=2) eval(args[i]+".location='"+args[i+1]+"'");
7}
8function JM_cc(ob){
9var obj=MM_findObj(ob); if (obj) {
10obj.select();js=obj.createTextRange();js.execCommand("Copy");}
11}
12
13function MM_findObj(n, d) { //v4.0
14var p,i,x; if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
15d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
16if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
17for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
18if(!x && document.getElementById) x=document.getElementById(n); return x;
19}
20//-->
21</script>
1<script language="JavaScript">
2<!--
3
4menuPrefix = 'menu'; // Prefix that all menu layers must start with
5// All layers with this prefix will be treated
6// as a part of the menu system.
7
8var menuTree, mouseMenu, hideTimer, doHide;
9
10function init() {
11ie4 = (document.all)?true:false;
12ns4 = (document.layers)?true:false;
13document.onmousemove = mouseMove;
14if (ns4) { document.captureEvents(Event.MOUSEMOVE); }
15}
16
17function expandMenu(menuContainer,subContainer,menuLeft,menuTop) {
18// Hide all submenus thats's not below the current level
19doHide = false;
20if (menuContainer != menuTree) {
21if (ie4) {
22var menuLayers = document.all.tags("DIV");
23for (i=0; i<menuLayers.length; i++) {
24if ((menuLayers[i].id.indexOf(menuContainer) != -1) && (menuLayers[i].id != menuContainer)) {
25hideObject(menuLayers[i].id);
26}
27}
28}
29else if (ns4) {
30for (i=0; i<document.layers.length; i++) {
31var menuLayer = document.layers[i];
32if ((menuLayer.id.indexOf(menuContainer) != -1) && (menuLayer.id != menuContainer)) {
33menuLayer.visibility = "hide";
34}
35}
36}
37}
38// If this is item has a submenu, display it, or it it's a toplevel menu, open it
39if (subContainer) {
40if ((menuLeft) && (menuTop)) {
41positionObject(subContainer,menuLeft,menuTop);
42hideAll();
43}
44else {
45if (ie4) {
46positionObject(subContainer, document.all[menuContainer].offsetWidth + document.all[menuContainer].style.pixelLeft - 10, mouseY);
47}
48else {
49positionObject(subContainer, document.layers[menuContainer].document.width + document.layers[menuContainer].left + 50, mouseY);
50}
51}
52showObject(subContainer);
53menuTree = subContainer;
54}
55}
56
57function showObject(obj) {
58if (ie4) { document.all[obj].style.visibility = "visible"; }
59else if (ns4) { document.layers[obj].visibility = "show"; }
60}
61
62function hideObject(obj) {
63if (ie4) { document.all[obj].style.visibility = "hidden"; }
64else if (ns4) { document.layers[obj].visibility = "hide"; }
65}
66
67function positionObject(obj,x,y) {
68if (ie4) {
69var foo = document.all[obj].style;
70foo.left = x;
71foo.top = y;
72}
73else if (ns4) {
74var foo = document.layers[obj];
75foo.left = x;
76foo.top = y;
77}
78}
79
80function hideAll() {
81if (ie4) {
82var menuLayers = document.all.tags("DIV");
83for (i=0; i<menuLayers.length; i++) {
84if (menuLayers[i].id.indexOf(menuPrefix) != -1) {
85hideObject(menuLayers[i].id);
86}
87}
88}
89else if (ns4) {
90for (i=0; i<document.layers.length; i++) {
91var menuLayer = document.layers[i];
92if (menuLayer.id.indexOf(menuPrefix) != -1) {
93hideObject(menuLayer.id);
94}
95}
96}
97}
98
99function hideMe(hide) {
100if (hide) {
101if (doHide) { hideAll(); }
102}
103else {
104doHide = true;
105hideTimer = window.setTimeout("hideMe(true);", 1000);
106}
107}
108
109function mouseMove(e) {
110if (ie4) { mouseY = window.event.y; }
111if (ns4) { mouseY = e.pageY; }
112}
113
114function itemHover(obj,src,text,style) {
115if (ns4) {
116var text = '<nobr><a href="' + src + '" class="' + style + '">' + text + '<\/a><\/nobr>'
117obj.document.open();
118obj.document.write(text);
119obj.document.close();
120}
121}
122
123onload = init;
124//-->
125</script>
1<style type="text/css">
2<!--
3.menu { position: absolute; top: 2;
4visibility: hidden; background: #000000;
5width: 79px; margin: 0px 0px; padding: 0px 0px;
6border: 1px silver solid;
7overflow: visible; ; clip: rect( )}
8.menu a:visited { font-family: "Tahoma"; font-size: 11px;
9text-decoration: none; font-weight: normal;
10background: #ffffff;
11width: 79px; padding-left: 8px; ; line-height: 22px;
12border-color: #000000 ; border-style: solid;
13border-width: 1px; clip: rect( )}
14.menu a:hover { font-family: "Tahoma"; font-size: 11px;
15text-decoration: none; font-weight: normal;
16background: #D6DFE7; color: #000000;
17width: 79px; padding-left: 8px; ; line-height: 22px;
18clip: rect( )}
19.menu .border { border: 1px solid #D6DFE7;}
20.menu .text { overflow: hidden;
21width: 79px; height: 15px; }
22.menu .arrow { overflow: hidden;
23width: 15px; height: 12px;
24padding-left: 5px; padding-top: 3px; }
25.menu .arrow img { width: 6px; height: 7px;
26border: 0px; } .menu a { font-family: "Tahoma";
27font-size: 11px;
28text-decoration: none; font-weight: normal;
29color: black; background: #ffffff;
30width: 79px; padding-left: 8px;
31clip: rect( ); border-color: #000000;
32border-style: solid; border-width: 1px; line-height: 22px} .menu a:link { color: #000000; text-decoration: none}
33
34.a { font-size: 12px; text-decoration: none}
35a:link { color: #000000; text-decoration: none}
36a:hover { text-decoration: underline}
37a:visited { color: #000000; text-decoration: none;}
38\-->
39</style>
1<div align="center">
2<table bgcolor="#D6DFE7" border="0" cellspacing="1" class="docbutton" width="85%">
3<tr>
4<td bgcolor="#D6DFE7" height="30" width="165"> <img border="0" height="13" src="../pic/point.gif" width="13"/></td>
5<td bgcolor="#D6DFE7" height="30"><div align="right"><a class="a" href="#;" onmouseover="expandMenu(null,'menu1',getPos(this,'Left'),getPos(this,'Top')+this.offsetHeight);">图片管理▼ </a></div></td>
6</tr>
7</table>
8</div>
1<script language="JavaScript">
2function getPos(el,sProp) {
3var iPos = 0
4while (el!=null) {
5iPos+=el["offset" + sProp]
6el = el.offsetParent
7}
8return iPos
9
10}
11</script>
<div id="menu1" cla