Read response in jquery
<p>I am using simplest code of Jquery to check if the request is made to server to check certain table column and return true or false accordingly....</p>

<pre><code>    $.ajax({
        type: "POST",
        url: "check_ajax_availablity.php",
        data: "user_name=" + user_name,

        success: function (server_response) {
            alert(server_response);                                
        }
    });
</code></pre>

<p>My PHP script is ...</p>

<pre><code>&lt;?php
    include 'admin_functions.php';
    if (isset($_REQUEST)) {
        $user_name = $_REQUEST['user_name'];
        $condition = " `UserName` = '" . $user_name . "'";
        $result = $oAdmFun-&gt;chk_records('login_admin', $condition);
        if ($result == TRUE) {
            return "N";
        } else {
            return "Y";
        }
    }
?&gt;
</code></pre>

<p>Issue is its alerting blank value...</p>
