Hi i am trying to convert the the following html code to asp.net mvc code. I've already moved the style header into a site.css file and i want to move script header into the site.master file.
It seems that the "onmouseover" function creates a runtime error. ANY help would be greatly appreciated.
THANKS
Suhail Alam
<html>
<head>
<title>link box</title>
<style>
#messageBox{
border-right: 1px solid #000000;
position: absolute;
width: 400px;
height: 150px;
z-index: 1;
background-color: #C0C0C0;
border-style: solid;
border-width: 1px;
display:none;
}
#closeButt{
width: 100%;
height: 25px;
z-index: 1;
cursor: pointer;
left: 0px;
top: 0px;
background-color: #808080;
}
#contents{
width: 100%;
height: auto;
z-index: 2;
}
</style>
<script type="javascript">
function show(obj,msg){
messageBox.style.top=obj.offsetTop
messageBox.style.left=obj.offsetLeft+obj.offsetWidth+5
contents.innerHTML=msg+"<p>"+obj.href
messageBox.style.display="block"
}
</script>
</head>
<body>
<p><a onmouseover="show(this,' This popup box is for information on electricity monitoring for the whole HOUSE.')">Whole House</a></p>
<p><a onmouseover="show(this,' This popup box is for information on electricity monitoring for the Individual Circuits')">Individual Circuits</a></p>
<p><a onmouseover="show(this,' This popup box is for information on electricity monitoring for the Individual Devices')">Individual Devices</a></p>
<div id="messageBox">
<div onclick="messageBox.style.display='none'" id="closeButt"> X Click to close</div>
<div id="contents"></div>
</div>
</body>
</html>
It seems that the "onmouseover" function creates a runtime error. ANY help would be greatly appreciated.
THANKS
Suhail Alam
<html>
<head>
<title>link box</title>
<style>
#messageBox{
border-right: 1px solid #000000;
position: absolute;
width: 400px;
height: 150px;
z-index: 1;
background-color: #C0C0C0;
border-style: solid;
border-width: 1px;
display:none;
}
#closeButt{
width: 100%;
height: 25px;
z-index: 1;
cursor: pointer;
left: 0px;
top: 0px;
background-color: #808080;
}
#contents{
width: 100%;
height: auto;
z-index: 2;
}
</style>
<script type="javascript">
function show(obj,msg){
messageBox.style.top=obj.offsetTop
messageBox.style.left=obj.offsetLeft+obj.offsetWidth+5
contents.innerHTML=msg+"<p>"+obj.href
messageBox.style.display="block"
}
</script>
</head>
<body>
<p><a onmouseover="show(this,' This popup box is for information on electricity monitoring for the whole HOUSE.')">Whole House</a></p>
<p><a onmouseover="show(this,' This popup box is for information on electricity monitoring for the Individual Circuits')">Individual Circuits</a></p>
<p><a onmouseover="show(this,' This popup box is for information on electricity monitoring for the Individual Devices')">Individual Devices</a></p>
<div id="messageBox">
<div onclick="messageBox.style.display='none'" id="closeButt"> X Click to close</div>
<div id="contents"></div>
</div>
</body>
</html>