JavaScript的广告图片 怎么在网页插入广告?代码要怎么写?比如我要在网页的左边显示一张图片 他会随着我的鼠标的滚动而滚动,怎么写?id什么的最好举个例子给我 谢谢 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 <!doctype html><html> <head> <meta charset="gb2312" /> <style> body { height:1850px; } div { position:absolute; top:0px; left:0; } </style> </head> <body> <div id="test"> <img src="http://avatar.profile.csdn.net/0/1/6/2_nglwcm.jpg" /> </div> <script> function $(o){return document.getElementById(o)} window.onscroll = function(){ $('test').style.top = (document.documentElement.scrollTop || document.body.scrollTop) + 'px' } </script> </body></html>参考下 懒人图库上有一些:http://www.lanrentuku.com/js/duilian.html 求一下拉菜单 字符串压缩 网页上的邮箱登陆 js 字符串 查出a-z的汉字和字母 使用focus();execCommand('delete')清除掉input显示文本内容后无法使焦点改变了 为何动态生成的页面,无法执行js代码呢? 求助:关于传递文本框值的问题 我想在IE中做出类似windows资源管理器一模一样的效果,不知哪里有例子可以参考? 谁帮我写一个页面的停留秒数,并显示在表单中,50分送上,急用! 由汉字或Unicode码得到GBK码 【分享】JavaScript版变速齿轮(纯JS/CSS实现) IE6和IE7js获取jquery的document对象
<!doctype html>
<html>
<head>
<meta charset="gb2312" />
<style>
body { height:1850px; }
div {
position:absolute; top:0px; left:0;
}
</style>
</head>
<body>
<div id="test">
<img src="http://avatar.profile.csdn.net/0/1/6/2_nglwcm.jpg" />
</div>
<script>
function $(o){return document.getElementById(o)}
window.onscroll = function(){
$('test').style.top = (document.documentElement.scrollTop || document.body.scrollTop) + 'px'
}
</script>
</body>
</html>参考下
http://www.lanrentuku.com/js/duilian.html