I am implementing a struts-based web application. With this
jsp page, buttons work perfectly in IE and Netscape7.0, but these buttons(add and save)do not work at all in Netscape4.7. Could anyone give me a hand? Thanks very much.
Here is the jsp code:
<%-- code start --%>
<%@ page language="java" %>
<%@ taglib uri="/WEB-INF/struts.tld" prefix="struts" %>
<%@ taglib uri="/WEB-INF/struts-bean.tld" prefix="bean" %>
<%@ taglib uri="/WEB-INF/struts-logic.tld" prefix="logic" %>
<%@ taglib uri="/WEB-INF/struts-html.tld" prefix="html" %>
<html>
<head>
<title>
Test</title>
</head>
<script language="Javascript">
function submitPage(button){
if (button=='add') {
document.forms[0].action = "../jsp/page1.do?task=add";
document.forms[0].submit();
}
if (button=='save') {
document.forms[0].action = "../jsp/page1.do?task=save";
document.forms[0].submit();
}
}
</script>
<body bgcolor="#FFFFFF" text="#000000" leftmargin="0" topmargin="0" marginwidth="0" marginheight="0">
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<html:form action="/jsp/test.do?task=get" name="testForm" type="formbeans.TestForm" scope="session">
<tr>
<td colspan="4"> </td>
</tr>
</html:form>
<tr>
<td colspan="4"> </td>
</tr>
<tr>
<td colspan="3">
<%--THE ADD BUTTON--%>
<html:link href="javascript:submitPage('add')"><html:img srcKey="imgRecSetNav.btnAdd.src" border="0"/></html:link>
<%--THE SAVE BUTTON--%>
<html:link href="javascript:submitPage('save')"><html:img srcKey="imgModFunct.btnSave.src" border="0"/></html:link>
</td>
<td width="19%"> </td>
</tr>
<tr>
<td colspan="4"> </td>
</tr>
</table>
</body>
</html>
<%-- code end --%>
Thanks again,
Nora