In javascript i would like to load a certain controller (and/or service) but only upon an event such as a button-click inside of another controller. How can i get javascript to avoid loading as soon as the view comes up?
Asked
Active
Viewed 12 times
0
-
11) try jQuery's $.ready() to wrap script loading – user1576978 Sep 26 '14 at 18:59
-
12) this magnificient awnser: http://stackoverflow.com/a/9899701/1576978 – user1576978 Sep 26 '14 at 19:03
-
13) set the controller to a variable and call it upon need, like: var contr1 = function(parmsS){}; //then later: contr1(); – user1576978 Sep 26 '14 at 19:04