http://www.jq22.com/demo/jdtime-141112205749/
<!--选择地区-->
<section class="express-area">
<a id="expressArea" href="javascript:void(0)">
<dl>
<dt>选择地区:</dt>
<dd>省 > 市 > 区/县</dd>
</dl>
</a>
</section>
<!--选择地区弹层-->
<section id="areaLayer" class="express-area-box" style="bottom: -100%;position: fixed;left: 0;height:100%;width: 100%;margin-left: 0;z-index:9999;">
<header>
<h3>选择地区</h3>
<a id="backUp" class="back" href="javascript:void(0)" title="返回"></a>
<a id="closeArea" class="close" href="javascript:void(0)" title="关闭"></a>
</header>
<article id="areaBox">
<ul id="areaList" class="area-list"></ul>
</article>
</section>
<!--遮罩层-->
<div id="areaMask" class="mask"></div>
function clockArea() { $("#areaMask").fadeOut(); $("#areaLayer").animate({"bottom": "-100%"}); intProvince(); } $(function() { /*打开省市区选项*/ $("#expressArea").click(function() { $("#areaMask").fadeIn(); $("#areaLayer").animate({"bottom": 0}); }); /*关闭省市区选项*/ $("#areaMask, #closeArea").click(function() { clockArea(); }); });
$("#aDatePicker").click(function(){ $("#m-calendar").animate({"bottom": "0"},300); $(document.body).css({ "overflow-x":"hidden", "overflow-y":"hidden" }); });
天数计算:total_ruzhu = (new Date(eDate)-new Date(sDate))/(1*24*60*60*1000)+1;
//滚动改变值
$(".ta_calendar_cont").scroll(function(){
// 获得窗口滚动上去的距离
var ling = $(".ta_calendar_cont").scrollTop();
// 在标题栏显示滚动的距离
document.title = ling;
if(ling<$('.ta_calendar_cont table').eq(0).height()){
$('.ta_calendar_cont table').find('caption').hide();
$('.ta_calendar_cont table').eq(0).find('caption').show();
}else if(ling>$('.ta_calendar_cont table').eq(1).height() ||ling<$('.ta_calendar_cont table').eq(2).height()){
alert('bb');
$('.ta_calendar_cont table').find('caption').hide();
$('.ta_calendar_cont table').eq(2).find('caption').show();
}else if(ling>$('.ta_calendar_cont table').eq(2).height() ||ling<$('.ta_calendar_cont table').eq(3).height() ){
$('.ta_calendar_cont table').find('caption').hide();
$('.ta_calendar_cont table').eq(3).find('caption').show();
}else if(ling>$('.ta_calendar_cont table').eq(3).height() ||ling>$('.ta_calendar_cont table').eq(4).height()){
$('.ta_calendar_cont table').find('caption').hide();
$('.ta_calendar_cont table').eq(4).find('caption').show();
}else if(ling>$('.ta_calendar_cont table').eq(4).height()){
$('.ta_calendar_cont table').find('caption').hide();
$('.ta_calendar_cont table').eq(5).find('caption').show();
}
})