【发布时间】:2017-03-01 09:10:17
【问题描述】:
我花了几天的时间尝试让它工作,但仍然没有运气。
我的问题是 url 出于某种原因重定向到 https 版本
所以可以说这是图片网址:
http://api.androidhive.info/images/sample.jpg
由于某种原因,图像重定向到 https 喜欢:
https://api.androidhive.info/images/sample.jpg
由于我的网站没有 https 它提供:
“无法访问此站点”
然后没有下载图片
我已经按照这个教程link
我正在使用 Picasso 加载来自 youtube 的所有 https url 工作的图像,但是当我调用没有 https 的 url 时它不起作用
这是我使用的android版本
android {
compileSdkVersion 25
buildToolsVersion "25.0.1"
defaultConfig {
applicationId "com.example.example"
minSdkVersion 19
targetSdkVersion 25
versionCode 1
versionName "1.0"
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
}
我不知道该怎么做任何帮助都会很棒。
【问题讨论】:
-
您是否尝试使用
Volley库来加载您的图像?请参考此链接:[truiton.com/2015/03/…