<html>
<head>
<title>jquery - 左边栏菜单隐藏/显示</title>
<script type="text/javascript" src="jquery-1.4.4.min.js" ></script>
<script>
$(document).ready(function(){
/** 通过点击展开左边栏 **/
$("#pull").click(function(){
if($("#mydiv").css("left") == "0px")
{
$("#mydiv").animate({left:"-150px"});
}
else
{
$("#mydiv").animate({left:"0px"});
}
});
/** 通过鼠标进出来展开与收缩左边栏 **/
/**
$("#pull").mouseover(function(){
$("#mydiv").animate({left:"0px"});
});
$("#pull").mouseout(function(){
$("#mydiv").animate({left:"-150px"});
});
**/
/** 首页连接 **/
$("#aIndex").click(function(){
$("#maindiv").load("http://xieruilin.iteye.com/");
});
});
</script>
<style>
#mydiv
{
width:200px;
height: 100%;
position: absolute;
top:0;
left:-150px;
}
#maindiv
{
width:100%;
height: 100%;
background:black;
position: absolute;
top:0;
left:0;
}
</style>
</head>
<body>
<div id="maindiv">
</div>
<div id="mydiv">
<div style="background:blue;width:150px;height:100%;float: left;color:#FFFFFF;">
<a id="aIndex" href="#">首页</a>
</div>
<div style="width:50px;height:100%;float: left;">
<div id="pull" style="background:blue;width:50px;height:40px;color:yellow;cursor:pointer;">
拉
</div>
</div>
</div>
</body>
</html>
分享到:
相关推荐
jquery-3.3.1.js/min.js
<link rel="stylesheet" type="text/css" href="${ctx}/plugins/jquery-ui-1.11.2/jquery-ui.css" > <script type="text/javascript" src="${ctx}/plugins/jquery-ui-1.11.2/external/jquery/jquery.js"></script> ...
2010/05/04 06:45 239,835 jquery-1.4.1-vsdoc.js 2010/05/04 06:45 168,792 jquery-1.4.1.js 2010/05/04 06:45 71,922 jquery-1.4.1.min.js 2010/04/05 16:11 234,929 jquery-1.4.2-vsdoc.js 2010/04/05 15:55 163,...
jquery-3.7.0.min.js(jQuery下载)jquery-3.7.0.min.js(jQuery下载)jquery-3.7.0.min.js(jQuery下载)jquery-3.7.0.min.js(jQuery下载)jquery-3.7.0.min.js(jQuery下载)jquery-3.7.0.min.js(jQuery下载)...
jquery-1.8.3.js jquery-1.8.3.js jquery-1.8.3.js jquery-1.8.3.js jquery-1.8.3.js jquery-1.8.3.js jquery-1.8.3.js jquery-1.8.3.js jquery-1.8.3.js
jquery框架最新版本:jquery-1.3.2.min.js
这里包含jquery-ui-1.8.16.custom.min.js/jquery-ui-1.8.16.custom.css,我费了好长时间找到的,此东西可以配合jQuery UI开发指南一书使用。
含下述资源: jquery-1.8.2.js jquery-1.8.2.min.js jquery-1.8.2-vsdoc.js jquery.cookie.js jquery1.8.2.chm
jquery-3.5.0.js jquery-3.5.0.min.js.zip
jquery-2.table2excels. 1、需要引入jquery.js和jquery.table2excel.min.js 2、增加绑定事件,例子: ------------------- //导出excel $("#output").click(function(){ var myDate = new Date(); $("#example")....
jquery-1.11.1.js 、jquery-1.11.1.min.js 【官方jquery包 js】
jquery-ui-1.11.4完整版
jquery1.7 API jquery-1.7.1.min.js jquery-1.7.1.js 最新Jquery1.7版本,三个文件放一起的压缩包,方便各位下载使用!
jquery-ui-日期框扩展成时间框 jquery-ui时间框 基于别人的代码进行修改 jquery-ui-1.8.16.custom.css文件末尾加入以下代码 .ui-timepicker-div .ui-widget-header{ margin-bottom: 8px; } .ui-timepicker-div dl{ ...
jquery-1.11.3.js 、jquery-1.11.3.min.js 【官方jquery包 js】
jquery-1.9.1.js 、jquery-1.9.1.min.js 【jquery包 js】
jquery-3.0.0.js 、jquery-3.0.0.min.js 【官方jquery包 js】
jQuery 是一个 JavaScript 库。jQuery 极大地简化了 JavaScript 编程。jQuery 很容易学习。
jquery-1.4.2.js和jquery.min-1.4.2.js
jquery.layout 布局插件精简版,对依赖ui.core和拖拽进行精简