codeigniter & DefaultHttpClient (java/Android) |
[eluser]Unknown[/eluser]
I am creating an android app requests info from my codeigniter based server. When the request is to just the url (www.example.com), it works fine and my app recieves whatever information is output to the browser. When i request something that more complicated (www.example.com/controller/function/variable/) I get the following error thrown from (java/Android) DefaultHttpCleint();. "org.apache.http.client.ClientProtocolException" the codeigniter url works well with a regular browser and even in the webView browser. here is relevant java code Code: HttpClient client=new DefaultHttpClient(); Code: public function update($accessKey, $fbid, $lat=0, $long=0){ Code: 24.205.233.149 - - [10/May/2011:19:19:06 -0700] "GET /locations/update HTTP/1.1" 302 - "-" "Apache-HttpClient/UNAVAILABLE (java 1.4)"
[eluser]Unknown[/eluser]
Sorry for wasting your time, turns out DefaultHttpClient(); doesnt support cookies, and because of that i had sent myself into an endless redirect loop(cause im a dumbass). If you want you guys can delete this, or keep it for reference.
[eluser]Atharva[/eluser]
[quote author="Terrortrain" date="1305101446"]Sorry for wasting your time, turns out DefaultHttpClient(); doesnt support cookies, and because of that i had sent myself into an endless redirect loop(cause im a dumbass). If you want you guys can delete this, or keep it for reference.[/quote] It happens...stop scolding yourself |
Welcome Guest, Not a member yet? Register Sign In |