function getFormatDate() { var day=new Date();
var Year=day.getYear(); var Month=day.getMonth()+1; var Day=day.getDate(); var Hour = day.getHours(); var Minute = day.getMinutes(); var Second = day.getSeconds(); var CurrentDate=""; if(Hour >=10) { CurrentDate = Hour ; } else { CurrentDate = "0" + Hour ; } if(Minute >=10) { CurrentDate = CurrentDate + ":" + Minute ; } else { CurrentDate = CurrentDate + ":0" + Minute ; } if(Second>=10) { CurrentDate = CurrentDate + ":" + Second; } else { CurrentDate = CurrentDate + ":0" + Second; } CurrentDate = CurrentDate + " " + Year + "/"; if (Month >= 10 ) { CurrentDate = CurrentDate + Month + "/"; } else { CurrentDate = CurrentDate + "0" + Month + "/"; } if (Day >= 10 ) { CurrentDate = CurrentDate + Day ; } else { CurrentDate = CurrentDate + "0" + Day ; }
return CurrentDate; } SW_DATE 64 10 1 1 255 不限制
CommunityBuilding UNIT ROOMNUMBER
<input name="txt_FilingDate_V9" type="text" id="txt_FilingDate_V9" format="yyyy-MM-dd HH:mm:ss" rule="/^(\d{4})(-|\/)(\d{2})\2(\d{2}) (\d{2}):(\d{2}):(\d{2})$/" ruleMsg="請輸入正確的日期格式!"/>
|