Android Question Download image

RUNO

Active Member
Licensed User
Longtime User
I am trying to download a picture from my site but it gives me this message for show not save

ResponseError. Reason: java.net.UnknownServiceException: CLEARTEXT communication to omxxxxx.com not permitted by network security policy, Response:

Before it was without problems from the free site but when I bought the domain I could not, so is there a difference between free or paid
 

RUNO

Active Member
Licensed User
Longtime User
OK, the problem is that the free link returns just data for an image, so Job1.Getbitmap works fine.

However, the paid link returns both text and an image, so because it is not just pure image data, the .GetBitmap is failing.

This was easily determined by opening both links in a browser.

It appears there is some code on the paid server that is doing a redirect to the homepage (with the text and image shown) when you try to access the image directly - maybe a header needs to be set when trying to download the image?

How I do that?
Can you give example please
 
Upvote 0

JohnC

Expert
Licensed User
Longtime User
Since you mentioned the second link is a "paid" link, then I would contact the company that owns the paid website and ask what is the properly way to download the images from their site.

They should be able to tell you what special codes, headers, tokens are needed to download the paid images.
 
Last edited:
Upvote 0

RUNO

Active Member
Licensed User
Longtime User
Since you mentioned the second link is a "paid" link, then I would contact the company that owns the paid website and ask what is the properly way to download the images from their site.

They should be able to tell you what special codes, headers, tokens are needed to download the paid images.

Can you do that ? I hope you get an answer .
I contacted them before but did not get a solution
 
Upvote 0

JohnC

Expert
Licensed User
Longtime User
I do not have enough free time to do that, sorry.
 
Upvote 0
Top