在IE中默认的都是vbsricpt的,所有javascript的都要加javasript:前缀,要不就报错
<td style="text-align:right;height:27px" valign="top"
colspan="6">
<input class="short_button_style"
onClick="
javaScript:
if ( document.getElementById('confirmFlg').value == '1' ) {
var n = showSaveConfirmMessage();
if (n == 1) {
document.applicationListForm.insertAction.value = '1';
document.applicationListForm.menuId.value = '222';
document.applicationListForm.submit();
return false;
}
if (n == 2) {
showDialog();
}
if (n == 3) {
return false;
}
}
showDialog();
"
type="button" value="印刷" tabindex="6">
</td>
colspan="6">
<input class="short_button_style"
onClick="
javaScript:
if ( document.getElementById('confirmFlg').value == '1' ) {
var n = showSaveConfirmMessage();
if (n == 1) {
document.applicationListForm.insertAction.value = '1';
document.applicationListForm.menuId.value = '222';
document.applicationListForm.submit();
return false;
}
if (n == 2) {
showDialog();
}
if (n == 3) {
return false;
}
}
showDialog();
"
type="button" value="印刷" tabindex="6">
</td>
《征服 Ajax ---Web 2.0 开发技术详解》 P/107 说,通常情况下,在JavaScript中可以使用两种形式将事件处理程序邦定到特定的事件中,分别是嵌入HTML标记以及使用对象的事件属性和attachEvent()方法。
通常事件处理程序并不会这么简单,而会包括多行JavaScript代码,但如果把所有的处理程序都放在onclick属性中(
语句间只能用分号隔开,不能换行)。<
但如上之例,可以换行啊
>
<td colspan="2"
style="text-align:left;vertical-align:bottom;font-weight:bold;">
<a tabindex="8"
style="color: blue;"
href="
javaScript:
document.applicationListForm.searchAction.value = 'theDayAfterTomorrow';
addOpePlanDay('2');
document.applicationListForm.submit();
">
翌々日未準備件数
<c:out value="${applicationList.afterTomorrowNoreadyCount}" />
件
</a>
</td>
style="text-align:left;vertical-align:bottom;font-weight:bold;">
<a tabindex="8"
style="color: blue;"
href="
javaScript:
document.applicationListForm.searchAction.value = 'theDayAfterTomorrow';
addOpePlanDay('2');
document.applicationListForm.submit();
">
翌々日未準備件数
<c:out value="${applicationList.afterTomorrowNoreadyCount}" />
件
</a>
</td>