【发布时间】:2010-03-25 16:06:19
【问题描述】:
我正在使用 jQuery Datepicker,但在编辑记录时遇到了问题。
// js code
$(function(){
$(".datepicker").datepicker().datepicker('option', 'dateFormat', 'yy-mm-dd').datepicker('option', 'changeMonth', 'true').datepicker('option', 'changeYear', 'true');
})
// the input
<input type="text" name="valid_from" value="2010-02-27" class="datepicker" />
但是当页面呈现时,显示的日期(并在我打开日期选择器时选择)是今天。
我真的不明白发生了什么。
【问题讨论】:
标签: javascript jquery jquery-ui datepicker