Ajax div 位置例子
728x15 ad here
出自Guoshuang Wiki
ie only,div 覆盖 select
<script type="text/javascript">
function getCutomer(key,oLeft,oTop,oWidth){
idMsgDiv = document.getElementById("idMsg");
idMsgDiv.style.left=oLeft;
idMsgDiv.style.top=oTop;
idMsgDiv.style.width=oWidth-10;
}
</script>
</head>
<body>
<style>
* {font-size:12px;}
body {margin:0;}
#idMsg {position:absolute;background:#fff;padding:4px;border:solid 1px;border-color:#fff #666 #666 #ccc;width:200px;overflow-x:hidden;white-space: nowrap;height:100px;overflow-y:scroll;background:#eee;filter:progid:DXImageTransform.Microsoft.shadow(color=#aaaaaa,direction=135,strength=4)}
#idMsg ul,#idMsg li {margin:0;padding:0;list-style:none;}
</style>
1111111111<p>11111<p>11111<p>11111<p>11111243253453453453453<input type="text" name="custTName" size="36" class="required" alt="blank" onkeyup="getCutomer(this.value,this.offsetLeft,this.offsetTop+this.offsetHeight,this.offsetWidth);" >
<div id="idMsg"><iframe src="iframe.htm" width="100%" frameborder="0"></iframe></div>
<input /><input /><br /><input /><input /><br /><select><option>注意避开select,会钻进来</option></select><input /><input /><br /><input /><input /><br /><input /><br /><input /><br /><input /><br /><input /><br /><input /><br /><input /><br />
