//1.定义一个日期函数
function CurentTime()
{
var now = new Date();
var year = now.getFullYear(); //年
var month = now.getMonth() + 1; //月
var day = now.getDate(); //日
var clock = year + "-";
if(month < 10)
clock += "0";
clock += month + "-";
if(day < 10)
clock += "0";
clock += day + "";
return clock;
}
//2.文本框
$("#start").val(CurentTime());
<s:text name="effectdate"></s:text>:</div></td><td colspan="3"><input id="start" type="text" onclick="WdatePicker()" name="systemnotice.startDate"/>
//3.图片效果