class=easyui-datebox
$(document).ready(function() {
$("#thedate").datebox("setValue",myformatter( new Date()));
$(".datebox :text").attr("readonly","readonly");
});
function myformatter(date){
var y = date.getFullYear();
var m = date.getMonth()+1;
var d = date.getDate();
return y+‘-‘+(m<10?(‘0‘+m):m)+‘-‘+(d<10?(‘0‘+d):d);
}
原文:http://www.cnblogs.com/baijin05/p/5040361.html