You can use the onerror attribute, just like this:
<img src="image.gif" onerror="myFunction()">
El miércoles, 10 de mayo de 2017, 11:14:44 (UTC-5), Szabo Zsolt escribió:
>
> I have two pictures: img.jpg, noimage.jpgng-src="
> www.example.com/{{imgurl}} <http://www.example.com/%7B%7Bimgurl%7D%7D>"How
> to check if ng-src path invalid and change default image?
>
> Thanks!
>
--
You received this message because you are subscribed to the Google Groups
"Angular and AngularJS discussion" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.