In my app i am calling image from url,its working in simulator but in device it shows tunnel failure probelm. I then appended "deviceside=true" if i test it in simulator and "interface=wifi" if i test it in device both shows "Unexpected Response code 301" error. Why it is so ? Guide me.
In my app i am calling image from url ,its working in simulator but
Share
301 is a “Moved Permanently” code. The actual body you receive will probably say where its actual location is. The browser gets this and can make sense of it, knowing to just forward itself to the new URL, but a normal connection is just grabbing the contents of whatever is at that location.
You can add some logic in there to follow the redirect, or just figure out what the actual URL is.