任何人都可以帮助我。我的代码是一个简单的JSP,点击日历图标就会调用JS文件。弹出日历。到现在为止还挺好。但是当我尝试点击dropdwon时,它不起作用。我无法选择选项。
var str_buffer = new String (
"<html>\n"+
"<head>\n"+
" <title>"+calendarText+"</title>\n"+
"</head>\n"+
"<body bgcolor=\"#4682B4\">\n"+
"<table class=\"clsOTable\" cellspacing=\"0\" border=\"0\" width=\"210\">\n"+
"<tr><td bgcolor=\"#4682B4\">\n"+
"<table STYLE=\"table-layout:fixed\" cellspacing=\"1\" cellpadding=\"3\" border=\"0\" width=\"100%\">\n"+
"<tr>\n"+
"<td colspan=7 width=210 height=30 align=center>\n");
str_buffer+=
"<SELECT ID=\"dropmonth\" style=\"font-family:Verdana, Geneva, Arial, "+
"Helvetica, sans-serif;font-size:10px;line-height:12px;"+
"background-color:#DBEAF5;color:black;width:100\" "+
"onchange=\"window.opener.rollCalendar(dropmonth,dropyear,"+
"'"+str_target+"','"+ dt2dtstr4(dt_datetime)+"')\">\n";
for(z=0;z<monthNames.length-1;z++) {
str_buffer+=
"<OPTION value=\""+(z)+"\"";
if(z == dt_datetime.getMonth())
str_buffer+=" SELECTED";
str_buffer+=">"+monthNames[z+1]+"</OPTION>\n";