Hi,
I have a form which works ony my site and it is fine for Explorer 4+ browsers but with Netscape 4+ browsers it ignores a lot of the script, this is what it ignores:
function detectbrowser()
{
Browsername=navigator.appName;
browser="0";
if (navigator.appVersion.indexOf("2.0"
) {browser="2"};
if (navigator.appVersion.indexOf("3.0"
) {browser="3"};
if (navigator.appVersion.indexOf("4.0"
) {browser="4"};
document.sale.code.value=navigator.appCodeName;
document.sale.sbrowser.value=navigator.appName;
document.sale.sversion.value=navigator.appVersion;
document.sale.sagent.value=navigator.userAgent;
document.sale.splatform.value=navigator.platform;
}
and this:
if (sale.country.options[0].selected) {
alert('Please select your country.');
{scountry.focus(); return false;};
and this:
return confirm('Is this information you have entered correct?\n\n ' + 'Title: ' + selectedsalItem + '\n ' + 'Name: ' + document.sale.name.value + '\n ' + 'E-mail address: ' + document.sale.email.value + '\n ' + 'Country: ' + document.sale.country.value + '\n\n\n ' + 'Press OK to continue or Cancel to make changes \n');
and also this:
<script language="JavaScript">
<!--
var now = new Date();
document.sale.sdate.value = now;
//-->
</script>
is there alternative script that I can use so that both Netscape 4+ and IE 4+ browsers understand and process it.
Thanks.
I have a form which works ony my site and it is fine for Explorer 4+ browsers but with Netscape 4+ browsers it ignores a lot of the script, this is what it ignores:
function detectbrowser()
{
Browsername=navigator.appName;
browser="0";
if (navigator.appVersion.indexOf("2.0"
if (navigator.appVersion.indexOf("3.0"
if (navigator.appVersion.indexOf("4.0"
document.sale.code.value=navigator.appCodeName;
document.sale.sbrowser.value=navigator.appName;
document.sale.sversion.value=navigator.appVersion;
document.sale.sagent.value=navigator.userAgent;
document.sale.splatform.value=navigator.platform;
}
and this:
if (sale.country.options[0].selected) {
alert('Please select your country.');
{scountry.focus(); return false;};
and this:
return confirm('Is this information you have entered correct?\n\n ' + 'Title: ' + selectedsalItem + '\n ' + 'Name: ' + document.sale.name.value + '\n ' + 'E-mail address: ' + document.sale.email.value + '\n ' + 'Country: ' + document.sale.country.value + '\n\n\n ' + 'Press OK to continue or Cancel to make changes \n');
and also this:
<script language="JavaScript">
<!--
var now = new Date();
document.sale.sdate.value = now;
//-->
</script>
is there alternative script that I can use so that both Netscape 4+ and IE 4+ browsers understand and process it.
Thanks.