<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>jQuery Datepicker</title>
<script type="text/javascript" src="jquery-1.3.2.js"></script>
<script type="text/javascript" src="jquery.datepick.js"></script>
<script type="text/javascript" src="jquery.datepick-zh-CN.js"></script>
<script type="text/javascript">
$(function() {
var nowdays = new Date();
var dateConfig = {
showOn: 'both', //二個都顯示
buttonImage: 'calendar.gif', //加載圖片
buttonImageOnly: true, //顯示圖片的地方有一個突出部分,這個就是隱藏那玩意的
changeFirstDay: false, //這個參數干什么的呢,星期一是日歷的第一個,不可以改動的
numberOfMonths: 2, //顯示二個月,默認一個月
minDate: nowdays, //顯示最小時間是今天
dateFormat: 'yy-mm-dd', //日期格式
yearRange: '-20:+20' //前后20年,不過這根minDate是今天有沖突,自己去試吧。
};
$('#goodplugin').datepick(dateConfig);
$('#showdate').datepick(dateConfig);
});
</script>
<link type="text/css" href="smoothness.datepick.css" rel="stylesheet" />
</head>
<body>
<h1>jquery 日歷插件舉例</h1>
<br>
<a href="datepick1.html">樣式1</a>
<br>
<a href="datepick2.html">樣式2</a>
<br>
<a href="datepick3.html">樣式3</a>
<br><br><br>
<div id="showdate"></div>
<br>
<br>
<div>左邊直接顯示,右邊要點擊<input type="text" id="goodplugin"/></div>
</body>
</html>
原文:
http://blog.51yip.com/jsjquery/884.html
http://blog.51yip.com/demo/datepick/datepick3.html
http://blog.51yip.com/demo/datepick/jquery-1.3.2.js
http://blog.51yip.com/demo/datepick/jquery.datepick.js
http://blog.51yip.com/demo/datepick/jquery.datepick-zh-CN.js
http://blog.51yip.com/demo/datepick/humanity.datepick.css
http://docs.jquery.com/UI/Datepicker#options
多個示例:
http://jqueryui.com/datepicker/
http://jqueryui.com/datepicker/#dropdown-month-year
http://www.open-open.com/ajax/ajax20080626102652.htm
http://polaris.blog.51cto.com/1146394/259318
http://www.eyecon.ro/datepicker/#about