jananraj
05-23-2009, 06:22 AM
<script language="javascript" type="text/javascript">
window.onerror = null;
var bName = navigator.appName;
var bVer = parseInt(navigator.appVersion);
var IE4 = (bName == "Microsoft Internet Explorer" && bVer >= 4);
var menuActive = 0;
var menuOn = 0;
var onLayer;
var timeOn = null;
function showLayer(layerName,aa){
var x =document.getElementById(aa);
var tt =findPosX(x);
var ww =findPosY(x)+20;
if (timeOn != null) {
clearTimeout(timeOn);
hideLayer(onLayer);
}
if (IE4) {
var layers = eval('document.all["'+layerName+'"].style');
layers.left = tt;
eval('document.all["'+layerName+'"].style.visibility="visible"');
}
else {
if(document.getElementById){
var elementRef = document.getElementById(layerName);
if((elementRef.style)&& (elementRef.style.visibility!=null)){
elementRef.style.visibility = 'visible';
elementRef.style.left = tt;
elementRef.style.top = ww;
}
}
}
onLayer = layerName
}
function hideLayer(layerName){
if (menuActive == 0)
{
if (IE4){
eval('document.all["'+layerName+'"].style.visibility="hidden"');
}
else{
if(document.getElementById){
var elementRef = document.getElementById(layerName);
if((elementRef.style)&& (elementRef.style.visibility!=null)){
elementRef.style.visibility = 'hidden';
}
}
}
}
}
function btnTimer() {
timeOn = setTimeout("btnOut()",600)
}
function btnOut(layerName){
if (menuActive == 0){
hideLayer(onLayer)
}
}
var item;
function menuOver(itemName,ocolor){
item=itemName;
itemName.style.backgroundColor = ocolor; //background color change on mouse over
clearTimeout(timeOn);
menuActive = 0
}
function menuOut(itemName,ocolor){
if(item)
itemName.style.backgroundColor = ocolor;
menuActive = 0
timeOn = setTimeout("hideLayer(onLayer)", 100)
}
function findPosX(obj)
{
var curleft = 0;
if (obj.offsetParent)
{
while (obj.offsetParent)
{
curleft += obj.offsetLeft
obj = obj.offsetParent;
}
}
else if (obj.x)
curleft += obj.x;
return curleft;
}
function findPosY(obj)
{
var curtop = 0;
if (obj.offsetParent)
{
while (obj.offsetParent)
{
curtop += obj.offsetTop
obj = obj.offsetParent;
}
}
else if (obj.y)
curtop += obj.y;
return curtop;
}
</script>
html part
<table valign=top cellpadding=0 cellspacing=0 width=100% border=0>
<tr><td bgcolor=#F7EBB1>
<table align=center><tr>
<td id=0 align=center class=cur> <b>HOME</b></td>
<td style="color: #ffffff;"> || </td><td id=1 align=center onmouseout=btnTimer() onmouseover=showLayer("Menu1",'1') class=menu> <b>about dr</b></td>
<td style="color: #ffffff;"> || </td><td id=2 align=center onmouseout=btnTimer() onmouseover=showLayer("Menu2",'2') class=menu> <b>ayurvead</b></td>
<td style="color: #ffffff;"> || </td><td id=3 align=center onmouseout=btnTimer() onmouseover=showLayer("Menu3",'3') class=menu> <b>vedicyoga</b></td>
<td style="color: #ffffff;"> || </td><td id=4 align=center onmouseout=btnTimer() onmouseover=showLayer("Menu4",'4') class=menu> <b>contact us</b></td>
</tr></table>
<div id=Menu1 style="position: absolute; border: 1px solid #000000; visibility:hidden; z-ndex: 1">
<table bgcolor=#ffeecc cellspacing=0 cellpadding=0 style="border-collapse: collapse;">
<tr height=25 onmouseout=menuOut(this,'#ffeecc') onmouseover=menuOver(this,'#FFFFFF')>
<td bgcolor=#000000> </td><td align=left>
<a class=asd href="dfsadf"> dr krishna varma </a> </td></tr>
<tr height=25 onmouseout=menuOut(this,'#ffeecc') onmouseover=menuOver(this,'#FFFFFF')>
<td bgcolor=#000000> </td><td align=left>
<a class=asd href="dsff"> dr velvizhi </a> </td></tr>
<tr height=25 onmouseout=menuOut(this,'#ffeecc') onmouseover=menuOver(this,'#FFFFFF')>
<td bgcolor=#000000> </td><td align=left>
<a class=asd href="dsff"> dr velmani </a> </td></tr>
</table></div>
<div id=Menu2 style="position: absolute; border: 1px solid #000000; visibility:hidden; z-ndex: 1">
<table bgcolor=#ffeecc cellspacing=0 cellpadding=0 style="border-collapse: collapse;">
<tr height=25 onmouseout=menuOut(this,'#ffeecc') onmouseover=menuOver(this,'#FFFFFF')>
<td bgcolor=#000000> </td><td align=left>
<a class=asd href="about ayurveda.htm"> about </a> </td></tr>
<tr height=25 onmouseout=menuOut(this,'#ffeecc') onmouseover=menuOver(this,'#FFFFFF')>
<td bgcolor=#000000> </td><td align=left>
<a class=asd href="fdsdf"> sareera shudhi </a> </td></tr>
<tr height=25 onmouseout=menuOut(this,'#ffeecc') onmouseover=menuOver(this,'#FFFFFF')>
<td bgcolor=#000000> </td><td align=left>
<a class=asd href="fdsdf"> mano shudhi </a> </td></tr>
<tr height=25 onmouseout=menuOut(this,'#ffeecc') onmouseover=menuOver(this,'#FFFFFF')>
<td bgcolor=#000000> </td><td align=left>
<a class=asd href="fdsdf"> athma shudhi </a> </td></tr>
</table></div>
<div id=Menu3 style="position: absolute; border: 1px solid #000000; visibility:hidden; z-ndex: 1">
<table bgcolor=#ffeecc cellspacing=0 cellpadding=0 style="border-collapse: collapse;">
<tr height=25 onmouseout=menuOut(this,'#ffeecc') onmouseover=menuOver(this,'#FFFFFF')>
<td bgcolor=#000000> </td><td align=left>
<a class=asd href="sdfdsf"> classes </a> </td></tr>
<tr height=25 onmouseout=menuOut(this,'#ffeecc') onmouseover=menuOver(this,'#FFFFFF')>
<td bgcolor=#000000> </td><td align=left>
<a class=asd href="sdfdsf"> standing </a> </td></tr>
<tr height=25 onmouseout=menuOut(this,'#ffeecc') onmouseover=menuOver(this,'#FFFFFF')>
<td bgcolor=#000000> </td><td align=left>
<a class=asd href="fdsdf"> sitting </a> </td></tr>
<tr height=25 onmouseout=menuOut(this,'#ffeecc') onmouseover=menuOver(this,'#FFFFFF')>
<td bgcolor=#000000> </td><td align=left>
<a class=asd href="fdsdf"> lying back </a> </td></tr>
<tr height=25 onmouseout=menuOut(this,'#ffeecc') onmouseover=menuOver(this,'#FFFFFF')>
<td bgcolor=#000000> </td><td align=left>
<a class=asd href="fdsdf"> lying front </a> </td></tr>
</table></div>
<div id=Menu4 style="position: absolute; border: 1px solid #000000; visibility:hidden; z-ndex: 1">
<table bgcolor=#ffeecc cellspacing=0 cellpadding=0 style="border-collapse: collapse;">
<tr height=25 onmouseout=menuOut(this,'#ffeecc') onmouseover=menuOver(this,'#FFFFFF')>
<td bgcolor=#000000> </td><td align=left>
<a class=asd href="sdfdsf"> sdfdsf </a> </td></tr>
<tr height=25 onmouseout=menuOut(this,'#ffeecc') onmouseover=menuOver(this,'#FFFFFF')>
<td bgcolor=#000000> </td><td align=left>
<a class=asd href="fdsdf"> sdff </a> </td></tr>
</table></div>
please help me.
window.onerror = null;
var bName = navigator.appName;
var bVer = parseInt(navigator.appVersion);
var IE4 = (bName == "Microsoft Internet Explorer" && bVer >= 4);
var menuActive = 0;
var menuOn = 0;
var onLayer;
var timeOn = null;
function showLayer(layerName,aa){
var x =document.getElementById(aa);
var tt =findPosX(x);
var ww =findPosY(x)+20;
if (timeOn != null) {
clearTimeout(timeOn);
hideLayer(onLayer);
}
if (IE4) {
var layers = eval('document.all["'+layerName+'"].style');
layers.left = tt;
eval('document.all["'+layerName+'"].style.visibility="visible"');
}
else {
if(document.getElementById){
var elementRef = document.getElementById(layerName);
if((elementRef.style)&& (elementRef.style.visibility!=null)){
elementRef.style.visibility = 'visible';
elementRef.style.left = tt;
elementRef.style.top = ww;
}
}
}
onLayer = layerName
}
function hideLayer(layerName){
if (menuActive == 0)
{
if (IE4){
eval('document.all["'+layerName+'"].style.visibility="hidden"');
}
else{
if(document.getElementById){
var elementRef = document.getElementById(layerName);
if((elementRef.style)&& (elementRef.style.visibility!=null)){
elementRef.style.visibility = 'hidden';
}
}
}
}
}
function btnTimer() {
timeOn = setTimeout("btnOut()",600)
}
function btnOut(layerName){
if (menuActive == 0){
hideLayer(onLayer)
}
}
var item;
function menuOver(itemName,ocolor){
item=itemName;
itemName.style.backgroundColor = ocolor; //background color change on mouse over
clearTimeout(timeOn);
menuActive = 0
}
function menuOut(itemName,ocolor){
if(item)
itemName.style.backgroundColor = ocolor;
menuActive = 0
timeOn = setTimeout("hideLayer(onLayer)", 100)
}
function findPosX(obj)
{
var curleft = 0;
if (obj.offsetParent)
{
while (obj.offsetParent)
{
curleft += obj.offsetLeft
obj = obj.offsetParent;
}
}
else if (obj.x)
curleft += obj.x;
return curleft;
}
function findPosY(obj)
{
var curtop = 0;
if (obj.offsetParent)
{
while (obj.offsetParent)
{
curtop += obj.offsetTop
obj = obj.offsetParent;
}
}
else if (obj.y)
curtop += obj.y;
return curtop;
}
</script>
html part
<table valign=top cellpadding=0 cellspacing=0 width=100% border=0>
<tr><td bgcolor=#F7EBB1>
<table align=center><tr>
<td id=0 align=center class=cur> <b>HOME</b></td>
<td style="color: #ffffff;"> || </td><td id=1 align=center onmouseout=btnTimer() onmouseover=showLayer("Menu1",'1') class=menu> <b>about dr</b></td>
<td style="color: #ffffff;"> || </td><td id=2 align=center onmouseout=btnTimer() onmouseover=showLayer("Menu2",'2') class=menu> <b>ayurvead</b></td>
<td style="color: #ffffff;"> || </td><td id=3 align=center onmouseout=btnTimer() onmouseover=showLayer("Menu3",'3') class=menu> <b>vedicyoga</b></td>
<td style="color: #ffffff;"> || </td><td id=4 align=center onmouseout=btnTimer() onmouseover=showLayer("Menu4",'4') class=menu> <b>contact us</b></td>
</tr></table>
<div id=Menu1 style="position: absolute; border: 1px solid #000000; visibility:hidden; z-ndex: 1">
<table bgcolor=#ffeecc cellspacing=0 cellpadding=0 style="border-collapse: collapse;">
<tr height=25 onmouseout=menuOut(this,'#ffeecc') onmouseover=menuOver(this,'#FFFFFF')>
<td bgcolor=#000000> </td><td align=left>
<a class=asd href="dfsadf"> dr krishna varma </a> </td></tr>
<tr height=25 onmouseout=menuOut(this,'#ffeecc') onmouseover=menuOver(this,'#FFFFFF')>
<td bgcolor=#000000> </td><td align=left>
<a class=asd href="dsff"> dr velvizhi </a> </td></tr>
<tr height=25 onmouseout=menuOut(this,'#ffeecc') onmouseover=menuOver(this,'#FFFFFF')>
<td bgcolor=#000000> </td><td align=left>
<a class=asd href="dsff"> dr velmani </a> </td></tr>
</table></div>
<div id=Menu2 style="position: absolute; border: 1px solid #000000; visibility:hidden; z-ndex: 1">
<table bgcolor=#ffeecc cellspacing=0 cellpadding=0 style="border-collapse: collapse;">
<tr height=25 onmouseout=menuOut(this,'#ffeecc') onmouseover=menuOver(this,'#FFFFFF')>
<td bgcolor=#000000> </td><td align=left>
<a class=asd href="about ayurveda.htm"> about </a> </td></tr>
<tr height=25 onmouseout=menuOut(this,'#ffeecc') onmouseover=menuOver(this,'#FFFFFF')>
<td bgcolor=#000000> </td><td align=left>
<a class=asd href="fdsdf"> sareera shudhi </a> </td></tr>
<tr height=25 onmouseout=menuOut(this,'#ffeecc') onmouseover=menuOver(this,'#FFFFFF')>
<td bgcolor=#000000> </td><td align=left>
<a class=asd href="fdsdf"> mano shudhi </a> </td></tr>
<tr height=25 onmouseout=menuOut(this,'#ffeecc') onmouseover=menuOver(this,'#FFFFFF')>
<td bgcolor=#000000> </td><td align=left>
<a class=asd href="fdsdf"> athma shudhi </a> </td></tr>
</table></div>
<div id=Menu3 style="position: absolute; border: 1px solid #000000; visibility:hidden; z-ndex: 1">
<table bgcolor=#ffeecc cellspacing=0 cellpadding=0 style="border-collapse: collapse;">
<tr height=25 onmouseout=menuOut(this,'#ffeecc') onmouseover=menuOver(this,'#FFFFFF')>
<td bgcolor=#000000> </td><td align=left>
<a class=asd href="sdfdsf"> classes </a> </td></tr>
<tr height=25 onmouseout=menuOut(this,'#ffeecc') onmouseover=menuOver(this,'#FFFFFF')>
<td bgcolor=#000000> </td><td align=left>
<a class=asd href="sdfdsf"> standing </a> </td></tr>
<tr height=25 onmouseout=menuOut(this,'#ffeecc') onmouseover=menuOver(this,'#FFFFFF')>
<td bgcolor=#000000> </td><td align=left>
<a class=asd href="fdsdf"> sitting </a> </td></tr>
<tr height=25 onmouseout=menuOut(this,'#ffeecc') onmouseover=menuOver(this,'#FFFFFF')>
<td bgcolor=#000000> </td><td align=left>
<a class=asd href="fdsdf"> lying back </a> </td></tr>
<tr height=25 onmouseout=menuOut(this,'#ffeecc') onmouseover=menuOver(this,'#FFFFFF')>
<td bgcolor=#000000> </td><td align=left>
<a class=asd href="fdsdf"> lying front </a> </td></tr>
</table></div>
<div id=Menu4 style="position: absolute; border: 1px solid #000000; visibility:hidden; z-ndex: 1">
<table bgcolor=#ffeecc cellspacing=0 cellpadding=0 style="border-collapse: collapse;">
<tr height=25 onmouseout=menuOut(this,'#ffeecc') onmouseover=menuOver(this,'#FFFFFF')>
<td bgcolor=#000000> </td><td align=left>
<a class=asd href="sdfdsf"> sdfdsf </a> </td></tr>
<tr height=25 onmouseout=menuOut(this,'#ffeecc') onmouseover=menuOver(this,'#FFFFFF')>
<td bgcolor=#000000> </td><td align=left>
<a class=asd href="fdsdf"> sdff </a> </td></tr>
</table></div>
please help me.