Android if value not working
<p>I am having problem,</p>

<pre><code>final Button button = (Button) findViewById(R.id.okBtn);
button.setOnClickListener(new View.OnClickListener() {
    public void onClick(View v) {
        String res = getServerData("http://10.0.2.2/auth.php?username="+username.getText()+"&amp;password="+password.getText());
        //txt.setText(res);
        if("true".equals(res))
            txt.setText("SUCESS");
        else
            txt.setText("FAILED");
    }
});
</code></pre>

<p>Why this conditions keep on FAILED even though if i uncomment txt.setText(res) it display as true. any idea why?</p>

<p>Thank you.. </p>
