View Single Post
Old 01-17-2013, 05:52 PM   PM User | #9
vwphillips
Senior Coder

 
Join Date: Mar 2005
Location: Portsmouth UK
Posts: 4,355
Thanks: 3
Thanked 458 Times in 445 Posts
vwphillips is a jewel in the roughvwphillips is a jewel in the roughvwphillips is a jewel in the rough
Code:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">

<head>
  <title></title>
<style type="text/css">
/*<![CDATA[*/

.nav_menu {
    position:relative;

}

table.sub_menu {
    visibility4: hidden;
}

.mdiv {
  position:absolute;
  overflow:hidden;
  visibility: hidden;
  z-Index:101;
  left:55px;
  top:55px;
  width:100px;
  height:0px;
  background-Color:#FFCC66;
}


/*]]>*/
</style>
<script type="text/javascript">
/*<![CDATA[*/

function showmenu(id,ms,ud) {
 var o=showmenu[id],obj=document.getElementById(id);
 if (!o&&obj){
  o=showmenu[id]=[obj,0,obj.getElementsByTagName('TABLE')[0].offsetHeight,0];
 }
 if (o&&obj){
  obj.style.visibility='visible';
  animate(o,o[3],o[ud?2:1],new Date(),ms);
 }
}

function animate(ary,f,t,srt,mS){
  clearTimeout(ary[4]);
  var oop=this,ms=new Date().getTime()-srt,now=(t-f)/mS*ms+f;
  if (isFinite(now)){
   ary[3]=Math.max(now,f<0||t<0?now:0);
   ary[0].style.height=ary[3]+'px';
  }
  if (ms<mS){
   ary[4]=setTimeout(function(){ oop.animate(ary,f,t,srt,mS); },10);
  }
  else {
   ary[3]=t;
   ary[0].style.height=t+'px';
   ary[0].style.visibility=t==0?'hidden':'visible';
  }
 }

function pos(obj){
  var rtn=[0,0];
  while(obj){
   rtn[0]+=obj.offsetLeft;
   rtn[1]+=obj.offsetTop;
   obj=obj.offsetParent;
  }
  return rtn;
 }


/*]]>*/
</script>

</head>

<body>
<table id="nav_menu">
<tr style="height:30px;" >
  <td style="height:30px;"><a href="index.html" class="no_submenu">Home</a></td>
  <td style="height:30px;" onmouseover="showmenu('about_us_menu',1000,true)" onmouseout="showmenu('about_us_menu',1000,false)">
    <a class="with_submenu">About Us <img src="images/menu_down.png" /></a>
  </td>
</tr>
</table>
    <div class="mdiv sub_menu" id="about_us_menu" onmouseover="showmenu('about_us_menu',1000,true)" onmouseout="showmenu('about_us_menu',1000,false)" >
     <table>
      <tr><td><a href="about_us/link1.html">link1</a></td></tr>
      <tr><td><a href="about_us/link2.html">link2</a></td></tr>
      <tr><td><a href="about_us/link3.html">link3</a></td></tr>
     </table>
    </div>


</body>

</html>
__________________
Vic

God Loves You and will never love you less.

http://www.vicsjavascripts.org.uk/

If my post has been useful please donate to http://www.operationsmile.org.uk/
vwphillips is offline   Reply With Quote