tags:

views:

36

answers:

3
$.post(
  "login.php", 
  { user: id, pass: ps, action: 'd56b699830e77ba53855679cb1d252da" },
  function(data){   
    var status = ($.evalJSON(data).oc);
    msgbox($.evalJSON(data).title,$.evalJSON(data).msg,status);
    if(status==1) { window.location = $.evalJSON(data).page; }
    } 
  );
+3  A: 

You have a quote mismatch.

Change it to

$.post(
  "login.php", 
  { user: id, pass: ps, action: 'd56b699830e77ba53855679cb1d252da' },
  function(data){   
    var status = ($.evalJSON(data).oc);
    msgbox($.evalJSON(data).title,$.evalJSON(data).msg,status);
    if(status==1) { window.location = $.evalJSON(data).page; }
    } 
  );

Also, Javascript has no msgbox function. Change it to alert and pass only one parameter. (Unless its a function you wrote yourself)

SLaks
+2  A: 

To start,

'd56b699830e77ba53855679cb1d252da"

should be

"d56b699830e77ba53855679cb1d252da"
Soufiane Hassou
+3  A: 

Your mistake is the quote, see the ending quote here 'd56b699830e77ba53855679cb1d252da"

Correction 'd56b699830e77ba53855679cb1d252da'

Sometimes you get stuck and then figure out its the most simplest thing in the world - :)
DMin