title: Ajax call result not working properly
body: <p>I have this function where on onkeyup it verifies the mobile number whether it exists in the database already or not now the issue is even if the response is "true" it will always show as false</p>
  
  <p>PHP</p>
  
  <pre><code>elseif ($action == 'check_mobile_phone')
  {
  
      $mobile = trim($_GET['mobile']);
      $mobile = json_str_iconv($mobile);
  
      if (mobile_register($mobile))
      {
          echo 'false';
      }
      else
      {
          echo 'true';
      }
  }
  </code></pre>
  
  <p>Ajax Call</p>
  
  <pre><code>function checkMobilePhone(mobile)
  {
  
    if (mobile == '')
    {
     error.find('#mobile_notice_text').html('Mobile number cant be empty.');
     submit_disabled = true;
    }
    else if (!Utils.isMobile(mobile))
    {
      error.find('#mobile_notice_text').html('Please enter mobile number in local format.');
    }
  
    if( submit_disabled )
    {
      document.forms['formUser'].elements['Submit'].disabled = 'disabled';
      return false;
    }
    Ajax.call( 'user.php?act=check_mobile_phone', 'mobile=' + mobile, check_mobile_callback , 'GET', 'TEXT', true, true );
  }
  </code></pre>
  
  <p>Response</p>
  
  <pre><code>function check_mobile_callback(result)
  {
    var logform = $('form[name="formUser"]');
    var error = logform.find('#mobile_notice');
  
    if ( result === "true" )
    {
      document.forms['formUser'].elements['Submit'].disabled = '';
    }
    else
    {
      error.find('#mobile_notice_text').html('Phone number already exists.');
      document.forms['formUser'].elements['Submit'].disabled = 'disabled';
    }
  }
  </code></pre>