Click to See Complete Forum and Search --> : Enter key not working in netscape4.76


tokanchana
April 25th, 2003, 01:32 AM
Hi all,

I have a html page with a text box. When I type some values in the text box and press 'Enter' key the form gets submitted. In the second page(which is having the same code as the first one), when a value is entered and Enter key is pressed it is not getting submitted. It says "Error 500 Server mapping error. The server is misconfigured." It is not even going to the function written in the Keypress event of the text box

The tags are checked and are correctly closed.

But when a new browser is opened for the same second html page Enter key is working fine.

Sometimes refreshing the page works. But only some times.

This works fine in higher version of netscape and in IE.

Thanks,
Kanchana:confused:

Satishpp
April 25th, 2003, 10:37 AM
I have a couple of quries

1) If your page is not getting submitted and if no function is getting called on pressing enter, where and how are you getting this "Error 500 Server mapping error. The server is misconfigured."

2) What web server are you using (This probably has nothing to do with your problem, but I just wanted to know since the error message you have mentioned is not a standard IIS error)

Finally, please post a section of the misbehaving code

Satish

tokanchana
April 27th, 2003, 10:57 PM
HI,

1. I don't know how this error is coming.

2. Iam using domino r5 as webserver. No errors are shown in domino when this error is thrown in html page.

This is the piece of code which I have written in key press event of the text box.

After the first time, the function PressEnter is not at all getting called.

function PressEnter() {
var browser = navigator.appName;
if (browser != "Netscape")
{ if (window.event.keyCode == 49 || window.event.keyCode == 13)
{
CheckBlank();
}
}
else
{
var version = parseInt(navigator.appVersion);
if (version >4){
CheckBlank();
}

else if (version <5) {

document.captureEvents(Event.KEYPRESS);
document.onkeypress= pressed;
function pressed(e)
{

if (e.which==13 || e.which ==49)
{
CheckBlank();
}
}}


}

}

tokanchana
May 2nd, 2003, 05:38 AM
Hi Sathish,

Thanks for the effort. It actually works when I use onSubmit in the form tag.

<FORM method=post name=SimpleSearch onSubmit="javascript:CheckBlank()">