Using AngularJS and IE11, image not updating upon updating the ng-src attribute of the image tag

耗尽温柔 提交于 2019-12-10 22:43:22

问题


I am using angularJS to change profilepics of users in my application. When a user uploads a new profile pic, I set the ng-src of the user's image tag to the updated URL that I receive from the backend. This works fine in chrome, firefox, but when it comes to IE11, the src gets updated using angular but the image does not show. IE shows it as a broken image link.

I am not sure what I am missing here. Could someone help me out here?

EDIT: I have to right click on the small black 'X' and then select 'Show Image', then the correct image displays.

EDIT: Below is my code

<img ng-src="{{profilePic}}">

来源:https://stackoverflow.com/questions/39000915/using-angularjs-and-ie11-image-not-updating-upon-updating-the-ng-src-attribute

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!