http://jsfiddle.net/fyv33/505/这个演示
这是我的代码
<script>
$(function() {
$( "#datepicker" ).datepicker({
changeMonth: true,
changeYear: true,
dateFormat: 'MM d, yy'
});
$( "#datepicker2" ).datepicker({
changeMonth: true,
changeYear: true,
dateFormat: 'MM d, yy'
});
});
</script>
<li><label for="billing_cycle">Billing</label>
<select name="billing_cycle" >
<option >monthly</option>
<option >6 months (5% off)</option>
<option >12 months</option>
<li><label for="charged_datetime">Charge Date</label>
<input type="text" id="datepicker" value="August 10,2012"></li>
<li><label for="expired_datetime">Expiring Date</label>
<input type="text" id="datepicker2" value="September 10,2012"></li>
每次我更改计费周期,过期日期也会更改,从收费日期开始。