onclick=XsetDate1("fromdate")其中:
function XsetDate1(xxx){
document.querysetting.fromdate.value="";
setDate(xxx);
}请问,怎样解释这个JS?
function XsetDate1(xxx){
document.querysetting.fromdate.value="";
setDate(xxx);
}请问,怎样解释这个JS?
function setDate(id)
{
try { newwin.close(); } catch(Exception) {}
td = document.forms[0].all[id].value;
today = new Date();
if (td == "") {
year = today.getYear();
if (year<100) year += 1900;
month = today.getMonth()+1;
} else {
year = td.substring(0,4)-0;
month = td.substring(5,7)-0;
}
newwin = window.open('','','height=240,width=164,top='+(event.screenY-100)+',left='+event.screenX);
newwin.document.write(getHTML(id,year,month));
}
querysetting和fromdate是HTML元素名称