I have to send this String(as XML data) to server:\[code\]<Vote> <ClientId>3</ClientId> <PollRunId>1</PollRunId> <VotingDateTime>2012-10-11T12:18:00</VotingDateTime> <VoterInfo>Javad 004912345678</VoterInfo> <VotedOptions> <VotedOption> <Id>2</Id> </VotedOption> </VotedOptions></Vote>\[/code\]I use this method to do this:\[code\] private static final String str = "http://.../"; private static InputStream is; ... public static void postXMLToUrl(String doc) { clientID = App.getClientID(); HttpClient client = new DefaultHttpClient(); String address = str; HttpPost post = new HttpPost(address); post.addHeader("Accept", "application/xml"); StringEntity s; try { s = new StringEntity(doc); s.setContentEncoding("UTF-8"); s.setContentType("text/xml"); post.setEntity(s); HttpResponse response = client.execute(post); is = response.getEntity().getContent(); } catch (Exception e) { e.printStackTrace(); } }\[/code\]When I invoke \[code\]postXMLToUrl\[/code\],in response I get an \[code\]error\[/code\] from server.So I debug this method and I saw \[code\]is\[/code\] vlaue is \[code\]org.apache.http.conn.EofSensorInputStream\[/code\].It is strange and I don't know how to solve it.I saw this question before,but it could not help me.