<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>jquery实现的可隐藏重现的靠边悬浮层_www.jb200.com</title>
<script type="text/
javascript" src="/pmedia/jquery-1.9.1.min.js"></script>
<style type="text/css">
body{ margin:0px;}
.onkeleyicom{left:0px;}
.offkeleyicom{left:-140px;}
.showkeleyicom{visibility:visible;}
.hidekeleyicom{visibility:hidden;}
#xf_keleyi_com{width:166px;height:200px; background-color:transparent;position:fixed;top:200px;}
#jt_keleyi_com{float:right;width:25px;height:25px;margin-top:80px;}
#nr_keleyi_com{float:left;height:100%;width:136px;background-color:Silver;}
</style>
</head>
<body>
<div style="background-color:#959822; width:100%;height:150px;">可以滚动鼠标使页面向下</div>
<div style="background-color:Green; width:100%;height:150px;">www.keleyi.com</div>
<div style="background-color:Red; width:100%;height:150px;">请把
光标移到箭头上</div>
<div style="background-color:Yellow; width:100%;height:150px;">hi</div>
<div style="background-color:Silver; width:100%;height:150px;">柯乐义</div>
<div style="background-color:Aqua; width:100%;height:150px;">keleyi.com</div>
<div style="background-color:Fuchsia; width:100%;height:150px;">keleyi</div>
<div style="background-color:Green; width:100%;height:150px;">keleyi.com</div>
<div style="background-color:Blue; width:100%;height:150px;">柯乐义</div>
<div style="background-color:Olive; width:100%;height:150px;">柯乐义 jquery实现的可隐藏重现的靠边悬浮层</div>
<div style="background-color:Green; width:100%;height:150px;">A</div>
<div style="background-color:Purple; width:100%;height:150px;">jquery</div>
<div style="background-color:Green; width:100%;height:150px;"><a href="/a/bjac/cdbc89174171ebb8.htm" target="_blank">原文</a></div>
<div style="background-color:Lime; width:100%;height:150px;">keleyi.com</div>
<div style="background-color:Orange; width:100%;height:150px;"><a href="/menu/jquery/" target="_blank">jQuery</a>完整代码</div>
<div class="offkeleyicom" id="xf_keleyi_com">
<div id="nr_keleyi_com">这里是内容<br />www.keleyi.com
<ul>
<li><a href="/menu/net/" target="_blank">.NET</a>
</li>
<li><a href="/menu/javascript/" target="_blank">Javascript</a>
</li>
<li><a href="/menu/jquery/" target="_blank">jQuery</a>
</li>
<li><a href="/menu/csharp/" target="_blank">C#</a>
</li>
<li><a href="/menu/other/" target="_blank">其他</a>
</li>
</ul>
<br />
</div>
<div id="jt_keleyi_com"><img src="/keleyi/pmedia/rightarrow.jpg" alt="显示" /></div>
</div>
<script type="text/javascript">
$(document).ready(
function () {
$('#jt_keleyi_com').bind('mouseover', function () {
$('#xf_keleyi_com').removeClass("offkeleyicom");
$('#xf_keleyi_com').addClass("onkeleyicom");
$('#jt_keleyi_com').addClass("hidekeleyicom");
$('#jt_keleyi_com').removeClass("showkeleyicom");
})
$('#nr_keleyi_com').bind('mouseleave', function () {
$('#xf_keleyi_com').removeClass("onkeleyicom");
$('#xf_keleyi_com').addClass("offkeleyicom");
$('#jt_keleyi_com').removeClass("hidekeleyicom");
$('#jt_keleyi_com').addClass("showkeleyicom");
})
})
</script>
</body>
</html>