if (resEntity != null) { res=EntityUtils.toString(resEntity); Log.i("RESPONSE",res); } xc=res.equals("true"); Log.i("xc",String.valueOf(xc)); if(xc) { Log.i("Yes","1"); } else { Log.i("no","0"); } above is my code in which i am sending a post request to our company server for checking a file it returns true if the file exists.I am providing my logcat.
09-24 11:20:19.570: I/url for checking update(3050): http://www.digitalmarketingbox.com/webtool/playerupdate.php 09-24 11:20:33.789: I/RESPONSE(3050): true 09-24 11:20:33.789: I/xc(3050): false as you can see,the response returned from server is true and i am also comparing it to true,so why equals() function is returning false ,please help me,or am i doing something wrong here?
res.length()?EntityUtils.toString(resEntity)return?