如何在 AngularJS 中动态获取单选按钮设置的值
要获取单选按钮值,请为每个 ng-model 添加 [$index],如下所示
<td><input type = "radio" ng-model = "classes.satisfies[$index]" value = "Country1"> India</td> <td><input type = "radio" ng-model = "classes.satisfies[$index]" value = "Country 2"> US</td>
上述内容将在 AngularJS 中动态提供结果。
广告
数据结构
网络
RDBMS
操作系统
Java
iOS
HTML
CSS
Android
Python
C 编程
C++
C#
MongoDB
MySQL
Javascript
PHP