I have been trying to incorporate videos using iframes, but no content is being displayed even with the correct embed link. Strangely, when I manually input the link into the iframe tag, the videos show up as expected. Here is the code snippet where I am facing the issue:
<ion-item ng-repeat="article in articles" class="item-light">
<img ng-show="article.external_media.length == 0 || article.external_media.url == ''" src="http://coop.app/imagecache/cover/{{article.cover_image}}">
<iframe ng-show="article.external_media.length > 0 && article.external_media.url != ''" src="{{article.external_media[0].url}}"></iframe>
</ion-item>
Update
Considering the need to include $sce dependency, I am unsure of how to implement it for all potential links within my controller. What would be the correct approach for this function?
Below is my controller setup:
.controller('FrontPageController', function($scope, ArticleService, $state) {
ArticleService.all().then(function(data){
$scope.articles = data;
})