Reputation: 2645
I'm trying to open links which come from a json in the system browser (android and iOS)
But the link the function generates is just this for example: {{item.addressLink}} instead of bit.ly/xyzxyz
This what i have:
<a href="#" ng-click="goToLink('{{item.addressLink}}')">
<i ng-hide="item.noPhoneAndMap === 1 || item.noMap === 1" class="fa fa-map fa-2x"></i>
</a>
<a href="#" ng-click="goToLink('{{item.link}}')">
<i ng-hide="item.noGlobe === 1" class="fa fa-globe fa-2x"></i>
</a>
The function looks like this
$scope.goToLink = function (url) {
window.open(url,'_system');
}
Upvotes: 0
Views: 112
Reputation: 944
try this
<a href="#" ng-click="goToLink(item.addressLink)">
<i ng-hide="item.noPhoneAndMap === 1 || item.noMap === 1" class="fa fa-map fa-2x"></i>
</a>
<a href="#" ng-click="goToLink(item.link)">
<i ng-hide="item.noGlobe === 1" class="fa fa-globe fa-2x"></i>
</a>
Upvotes: 1