Reputation: 2165
I need to process some parameters inside a controller and generate a link to a template. I cannot figure out how I try to pass assign {{url}}
<button class="button" onclick="window.open('{{url}}', '_system', 'location=yes'); return false;">open</button>
http://www.someurl.com/someservice.php?param=param&anotherparam=another
How can it be done?
Upvotes: 1
Views: 205
Reputation: 136134
You should use ng-click
without interpolation {{}}
in it.
Markup
<button class="button" type="button" ng-click="window.open(url, '_system', 'location=yes'); return false;">
open
</button>
Upvotes: 1
Reputation: 1147
You can't call angular code inside js onclick
. you must use ng-click
instead.
<button class="button" ng-click="window.open('{{url}}', '_system', 'location=yes'); return false;">open</button>
Upvotes: 1