削除確認ボタンで複数の関数を呼び出すにはどうすればよいですか?
呼び出す必要がある関数は次のとおりです。
function ifnull() {
if (selected_devices_area = "") {
window.alert("Please select devices!");
}
}
function submitForm() {
if (confirm("Do you really want to delete these devices?")) {
//document.location.href = '/site/service/device/DeleteMultipleDevices.asp?siteId=<%=iSiteId%>&serviceId=<%=iServiceId%>';
document.device.submit();
window.alert('Devices successfully deleted.');
}
ボタンの HTML:
<tr>
<td><a href="/site/service/serviceinfo_main.asp?siteId=<%=iSiteId%> &crType=Delete Multiple Devices&addCr=yes&crId=<%=iCrId %>"class="btnLink">« Back</a></td>
<td class="tdRight"><a href="javascript:ifnull();javascript:submitForm();" class="btnLink">Confirm Deletion »</a></td>
</tr>
</table>
このように関数を呼び出していますが、機能していません。