急~~~~~~~~~~~求一个像http://www.ifeng.com/页面里面效果的层 打开http://www.ifeng.com/页面,页面的中央就会弹出一个层,有时候他会在右下角。点击按钮他就显示出来了。再点就回到右下角。谁有有这方面的代码或者网址。急~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 nnd,凤凰网中间跳出来的广告真恶心~虽然一会就靠边了 看你是美女,帮你写一个吧,原理很简单,2个div,点A自己隐藏,B显示点B自己隐藏,A显示<div id="div1" onclick="this.style.display='none';document.getElementById('div2').style.display='';" style="background:#fff url(http://www.wholesale-retailer.com/zzz_js/old/aaa.gif) no-repeat;width:250px;height:250px; position:absolute;left:400px;top:300px;"></div><div id="div2" onclick="this.style.display='none';document.getElementById('div1').style.display='';" style="background:#fff url(http://www.wholesale-retailer.com/zzz_js/old/bbb.gif) no-repeat;cursor:pointer;position:absolute;width:20px;height:200px;right:0px;bottom:0px; display:none;"></div> 谢谢你michaelzhouh 也许你的代码是好用的,按照你的思路:http://www.ifeng.com/凤凰网的层是用两个层做的,但是我不大会js,它的一个层是在中间,随着滚动条的移动而移动,另一个是一个右下角。而且两个层和窗体的相对位置不变。 请问michaelzhouh,能不能劳驾你再帮一下啊。能实现我说的这两个功能,谢了。 <style type="text/css"><!--#cao { background-color: #3366FF; height: 200px; width: 200px; position: fixed; top:50%; left:50%; margin-left:-100px; margin-top:-100px;}body,td,th { font-size: 12px; text-align: center;}--></style><body><div id="cao">CAO888</div></body>保证好使,这个是中间的,右下角的你自己想想就能出来。应该说css就几句代码就能实现,太强大了 弹出对话框背景变灰问题 天涯“只看楼主”脚本 不唐突的javascript事件绑定问题 javascript 中的正则表达式及||运算(高手请进) 验证显示问题? select中设置超连接的问题 听说Eclipse有两个免费的JavaScript插件,是什么名字呢? 请教高手:<a href="Javascript:window.close();">关闭</a>问题 表单问题 自动提交表单 JS在火狐浏览器中动态读取远程XML 一个很奇怪的问题,关于js的函数
点B自己隐藏,A显示<div id="div1" onclick="this.style.display='none';document.getElementById('div2').style.display='';" style="background:#fff url(http://www.wholesale-retailer.com/zzz_js/old/aaa.gif) no-repeat;width:250px;height:250px; position:absolute;left:400px;top:300px;"></div>
<div id="div2" onclick="this.style.display='none';document.getElementById('div1').style.display='';" style="background:#fff url(http://www.wholesale-retailer.com/zzz_js/old/bbb.gif) no-repeat;cursor:pointer;position:absolute;width:20px;height:200px;right:0px;bottom:0px; display:none;"></div>
也许你的代码是好用的,按照你的思路:http://www.ifeng.com/凤凰网的层是用两个层做的,但是我不大会js,它的一个层是在中间,随着滚动条的移动而移动,另一个是一个右下角。而且两个层和窗体的相对位置不变。 请问michaelzhouh,能不能劳驾你再帮一下啊。能实现我说的这两个功能,谢了。
<!--
#cao {
background-color: #3366FF;
height: 200px;
width: 200px;
position: fixed;
top:50%;
left:50%;
margin-left:-100px;
margin-top:-100px;
}
body,td,th {
font-size: 12px;
text-align: center;
}
-->
</style>
<body>
<div id="cao">CAO888</div>
</body>
保证好使,这个是中间的,右下角的你自己想想就能出来。应该说css就几句代码就能实现,太强大了