Quantcast
Channel: Ionic Forum - Latest posts
Viewing all articles
Browse latest Browse all 228595

Access to dynamic/programtically created $scope variables

$
0
0

Solved this once I realized that $scope.pagedata is a JSON object (duh) - I was not indexing correctly. So rather than $scope['pagedata.name1'] it should be $scope.pagedata['name1]. If there is point notation then that needs to be expanded. Say if it is $scope.pagedata.CQ.isStudent then you can get the data by $scope.pagedata['CQ']['isStudent'].
Hope this helps others. I am still learning Ionic, AngularJS etc...


Viewing all articles
Browse latest Browse all 228595

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>