Questions tagged [loopj]

Use this tag for the HTTP Client for Android developed by James Smith, alias Loopj.

Loopj (loopj.com) is website and twitter handle of James Smith, a British entrepreneur and engineer based in San Francisco.

As a tag, it is mostly used for HTTP Client for Android developed by him.

http://loopj.com/android-async-http/

240 questions
2
votes
1 answer

What is the most optimal way to upload large data to server from an Android App?

I have an Android App that needs to upload, download data files between 10-12MB relatively often. Given that my app is more popular in countries like India which may not have good internet connectivity I am working under following constraints User…
2
votes
2 answers

Loopj HTTP library session id cookie not working

I am using Loopj HTTP client to make my http requests to my server (http://loopj.com/android-async-http/). Requests are working perfectly. However, I am trying to implement sessions into the service. From the documentation, enabling cookies through…
Pacemaker
  • 1,117
  • 2
  • 17
  • 36
2
votes
2 answers

loopj AsyncHttpClient more then 3 post not working

I am starting then 4 post after each other. But I catch only response from 3 of the 4 posts. Can somebody explain to me why? I tried it also with get and it has the same problem. Am I doing the posts to quick after each other? Resclient…
kevingoos
  • 3,785
  • 4
  • 36
  • 63
2
votes
1 answer

How to set uploaded jpg type to be recognised as "image/jpg" instead of "application/octet-stream"

I am using Loopj's android-async-http This is my code: File file = new File("sdcard/food.jpg"); params.put("image", file); My problem is, php server received the images as application/octet-stream instead of image/jpg. I need it to be image/jpg as…
ariefbayu
  • 21,849
  • 12
  • 71
  • 92
2
votes
2 answers

The loopj android-async-http request sometimes didn't response at all

I'm using this library to request from my web services. It didn't response at all in onSuccess and onFailure sometimes (these are the only two methods I overrides). I tested under 1.4.4 and 1.4.5 (android-async-http-1.4.5-20131110.125018-1, this one…
Bagusflyer
  • 12,675
  • 21
  • 96
  • 179
2
votes
1 answer

Calling numerous Android loopj AsyncHttpClient HEAD requests, just a random number of them is being executed

As the title says, I'm having a strange issue with loopj's AsyncHttpClient. MyObject is a class that contains a link and a value and lista is a List containing 50 MyObject objects. I need to retrieve header information from 50 links, so I've made a…
2
votes
1 answer

New relic for android: can new relic track http requests made using loopj (android-async-http)?

I'm using loopj to make http requests in my android app. I've recently added new relic and so far I don't see any of my app's http requests showing up in the dashboard. I do see other data streaming through new relic, but nothing on http…
James
  • 5,273
  • 10
  • 51
  • 76
2
votes
1 answer

Android: async loaded bitmaps randomly don't appear in ImageView after ImageView.setBitmapDrawable(..)

I have a ListView whose elements are photos I need to load from a remote API which I'm using loopj to access. After loopj downloads the photo data, I use an AsyncTask to process the data into a scaled bitmap. This usually works great, however.. The…
James
  • 5,273
  • 10
  • 51
  • 76
2
votes
1 answer

android-async-http Status code and response to onFailure

if failure authorization my http server send response: 401, binary "401" and send "close socket" When i test it, send command in CURL, i have: HTTP/1.1 401 Unauthorized date: Sat, 12 Oct 2013 10:16:31 GMT content-length: 3 connection:…
Kozlov V
  • 146
  • 5
  • 17
2
votes
1 answer

Associating responses with specific requests using Loopj Android Asynchronous Http Client

I'm using The Loopj Android Asynchronous HTTP Client to send multiple HTTP requests asynchronously. I'm using a static AsyncHttpClient as suggested and sending multiple HTTP posts and receiving responses on an anonymous class. The problem is that…
scoleman2272
  • 358
  • 6
  • 18
2
votes
0 answers

Racing condition in android instant search implementation

I am implementing instant search in an Android app which fetches the search results from REST services. I want to avoid the racing conditions when app fires multiple calls. Any idea on how to implements this? I am using AsyncHttpClient(loopj) for…
CodeFury
  • 1,520
  • 16
  • 29
2
votes
2 answers

How can I make two simultaneous Http Requests with Loopj AsyncHttpLibrary in Android?

I am using Loopj AsyncHttpLibrary for an android application. My purpose is to show a page containing some questions and corresponding answers. The Rest API, that I am coding against, serves questions and answers at different endpoints…
canerbalci
  • 1,239
  • 1
  • 12
  • 16
2
votes
3 answers

Trying to display url in Web View

I am experimenting with the loopj package. I am trying to make a HTTP request to a website and display the website in the webview. I am successfully getting a result back, however the web view does not display the page as desired, instead chrome…
Javacadabra
  • 5,578
  • 15
  • 84
  • 152
2
votes
0 answers

Can't submit Content-Type with Post using loopj android-async-http and an authorization header

I'm using loopj/android-async-http after having the same problem with the ignition project. When I submit a GET, without the authorization header, things work fine: AsyncHttpClient client = new AsyncHttpClient(); client.get(url, params,…
DaShaun
  • 3,722
  • 2
  • 27
  • 29
1
vote
1 answer

how can I integrate loopj for a json parse

These are the instructions in my onCreate: protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_main); Client c = new Client(); String p=c.get(); ((TextView)…
Tappo
  • 31
  • 3