...

View Full Version : popup menu probs



johns311
04-12-2005, 11:33 PM
Could you run through this code and tell me why when I use popup() that the menu does not keep it's formatting? Also I am trying to make the popup window close when the mouse moves out of it. Thanks!!



<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<title>Untitled Document</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">

<script>
var oPopup = window.createPopup();
function richDropDown(a,b,c,d,e,menu_name)
{
oPopup.document.body.innerHTML = menu_name.innerHTML;
oPopup.show(a,b,c,d,e,menu_name);
}
</script>


</head>

<body bgcolor="#CCCCCC">

<BUTTON name="butt" onclick="richDropDown(260,150, 200, 80, butt, MYMENU)">Toggle Transition</BUTTON>



<div id="MYMENU" style="display:block; background:#0066FF; border-style:outset; border-color:#FFFFFF; text-align:center; font-family:Arial, Helvetica, sans-serif; font-weight:bold; font-size:16; padding-top:15px; height:30px; width:200px; position:absolute; top:150px; left:50px;"> <!--onMouseOver="this.style.visibility='visible';" onmouseout="this.style.visibility='hidden';" >-->MY MENU

<div style="background-color:#CCCCCC; height:20px; border-top:2px solid black; border-style:outset; font-weight:normal; font-size:12px; cursor:hand;" onMouseOver="this.style.fontSize='16'; this.style.fontStyle='italic'; " onMouseOut="this.style.fontSize='12'; this.style.fontStyle='normal';">option 1</div>

<div style="background-color:#CCCCCC; height:20px; border-top:1px solid black; border-style:outset; font-weight:normal; font-size:12px; cursor:hand;" onMouseOver="this.style.fontSize='16'; this.style.fontStyle='italic'; " onMouseOut="this.style.fontSize='12'; this.style.fontStyle='normal';" >option 2</div>

<div style="background-color:#CCCCCC; height:20px; border-top:1px solid black; border-style:outset; font-weight:normal; font-size:12px; cursor:hand;" onMouseOver="this.style.fontSize='16'; this.style.fontStyle='italic'; " onMouseOut="this.style.fontSize='12'; this.style.fontStyle='normal';" >option 3</div>

</div>

</body>
</html>

johns311
04-13-2005, 02:09 AM
anyone have time to check this out or is this just not the way to do this.



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum