简体   繁体   中英

Load image failed when URL contains symbol '&'

I used UniversalImageLoader in android project, It unable to load image when the URL contains symbol '&', and I replace all the symbol "&" to the "%26", it doesn't work. The URL like this:

http://baike.baidu.com/picture/71563/71563/0/10dfa9ec8a136327e14f5154938fa0ec08fac733#
aid=0&pic=10dfa9ec8a136327e14f5154938fa0ec08fac733

It has nothing to do with the "&". You can't fetch that picture with UniversalImageLoader because the URL you used is wrong. It's a HTML page URL, no the image Url. In fact the URL of the Image that you want to fetch is:

http://d.hiphotos.baidu.com/baike/c0%3Dbaike150%2C5%2C5%2C150%2C50%3Bt%3Dgif/sign=5aac6ec2d343ad4bb2234e92e36b31ca/10dfa9ec8a136327e14f5154938fa0ec08fac733.jpg

You can right click on that picture and copy its URL to see.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM