我想从我的PHP服务器拍照并将其放入我的android ListView中
我在 https://www.simplifiedcoding.net/android-programming-tutorial-to-get-all-images-from-server 中使用了代码示例,但这只获取所有图像并逐个显示它们。
你真的应该尝试使用Android Volley进行数据传输。它由Android团队开发,是推荐的约定。
http://developer.android.com/training/volley/index.html
就您的列表视图而言,除非您有特定的原因使用它,否则您可能需要查看Recyclerview。它处理大部分加载和视图保留问题。http://developer.android.com/training/material/lists-cards.html#RecyclerView
使用安卓毕加索图书馆通过网址将图像传输到您的应用程序,它非常易于使用。查看本教程,了解毕加索的使用
http://javatechig.com/android/how-to-use-picasso-library-in-android希望这有帮助。
另一个选项是通用图像加载器。 https://github.com/nostra13/Android-Universal-Image-Loader