I need to check that two conditions are both true before enabling a button:
Here is an example:
<button type="submit" ng-disabled="frmUser.pw2.$error.pwMatch" class="btn btn-primary" ng-click="ChangePassword()">Change</button>
This example only contains one condition within ng-disabled
. How would I add another such as a scope variable?
Wanny is correct. The
&&
operator doesn't work in HTML. With Angular, you must use the double pipes (||
)for multiple conditions.