tags:

views:

36

answers:

1

i have following code which work fine in Firefox, Safari

but not working in internet explorer,

   $.post(postFile, { usernamePost: username, passwordPost: password }, function(data)    {
if(data.status==true)
     {
    $("#message").html("Correct Username or Password");
$("#message").css({color:"green"});
   else {
$("#message").html("Wrong Username or Password");
$("#message").css({color:"red"});
    }
   }, "json");
  return false;
   });

and html for message is .....

Thanks

A: 

Your syntax is mis-structured (missing a brace to the left of else)

Try:

$.post("test.php", { usernamePost: username, passwordPost: password },
    function(data){
        if(data.status==true){
            $("#message").html("Correct Username or Password");
            $("#message").css({color:"green"});
        }else{
            $("#message").html("Wrong Username or Password");
            $("#message").css({color:"red"});
        }
    }, "json");
micahwittman
not working same
air