【发布时间】:2019-12-12 17:27:08
【问题描述】:
我已将图像存储到服务器端的文件夹和数据库中。 我可以从 api 调用中取回图像,但是它不会显示在我的 html 中。我只得到?盒子。
查看图片
viewImage() {
individuals = [];
this.viewService.viewImage(this.id).subscribe((res: any) => {
console.log(res);
this.pImages = res.patients.data;
// console.log(res.patients.data);
console.log('IMAGES');
console.log(JSON.stringify(this.pImages));
});
}
html
<ion-col *ngFor='let img of pImages'>
<img [src] = "'http://ccoulter12.lampt.eeecs.qub.ac.uk/api/'"img.Image />
【问题讨论】:
标签: angular image ionic-framework