52
rated 0 times
[
57]
[
5]
/ answers: 1 / hits: 73736
/ 11 Years ago, fri, january 3, 2014, 12:00:00
I have a weird problem with passing a boolean to a text. Here is jsfiddle
<div ng-app ng-controller=MainCtrl>
<p>First Name:
<input ng-model=first ng-readonly=true/>
</p>
<p>Last Name:
<input ng-model=second ng-readonly={{truefalse}}/>
</p>
</div>
function MainCtrl($scope) {
$scope.first = Angular;
$scope.second = JS;
$scope.truefalse = true;
}
Can someone explain me why second field is still modifiable?
More From » angularjs