Here’s my code it works fine in IE and Chrome, but not in FF
<script type="text/javascript">
function get() {
$.post(
'regAuth.php',
{usrName: login.usrName.value, password: login.password.value},
function (output) {
$('#error').html(output).show();
}
);
}
</script>
You have to get the input elements properly:
When you have such thing:
Some browsers will go and look for top level element named
login(form, frame etc) but you must not depend on such thing.As you’re already using jQuery best practice in my opinion is to use it to read the input values as well.