<script>
var getit = function(n) {
return(document.getElementById(n));
}
var addit = function(n) {
getit('editform').style.visibility = "";
getit('editframe').src = 'add.asp?key=' + n;
}
</script>
<body>
<div style="position:absolute; top:50%; left:50%; margin:-100px 0 0 -150px; visibility: hidden;" id="editform">
<iframe id="editframe" frameborder=0 width=300 scrolling="no" marginheight="0" marginwidth="0" onload="this.style.height = editframe.document.body.scrollHeight" ></iframe>
</div>
<a href="javascript: addit();">填写留言</a>
点填写留言显示iframe可这个iframe不随垂直滚动条而移动,造成一定的麻烦,不知道有没有办法写成永远在显示屏幕的中间
[此贴子已经被作者于2007-8-13 13:28:36编辑过]