AngularJS Finding all Hidden Input in a scope WITHOUT Jquery
What is a way of finding all hidden input in a scope of a controller? And
ideally can this be done when the controller is initizialied?
In my example I have mutliple comments like this:
<div ng-controller="CommentCtrl">
<form method="post">
<label>Leave Comment</label>
<textarea name="comment" ng-bind="comment"></textarea>
<input type="hidden" name="comment_id" value="1" />
<input type="hidden" name="site_id" value="2" />
</form>
</div>
So I the init, I only want to iterate through scope to find the hidden
values of that controller and then assign it a value. Is there a way I can
do this in AngularJS?
No comments:
Post a Comment