AngularJS HTML DOM
AngularJS HTML DOM
AngularJS는 응용 프로그램 데이터를 HTML DOM 요소의 속성에 바인딩하기위한 지시문을 가지고 있습니다.
ng-disabled 지시어
NG 장애인 지시어는 HTML 요소의 disabled 속성에 AngularJS와 응용 프로그램 데이터를 결합한다.
예
<div ng-app="" ng-init="mySwitch=true">
<p>
<button ng-disabled="mySwitch">Click Me!</button>
</p>
<p>
<input type="checkbox" ng-model="mySwitch">Button
</p>
<p>
{{ mySwitch }}
</p>
</div>
신청 설명 :
NG 장애인 지시자는 애플리케이션 데이터 바인딩 mySwitch 는 HTML 버튼의에 사용할 속성을.
NG 모델 지시어의 값으로 HTML 체크 박스 요소의 값 결합 mySwitch을 .
mySwitch 의 값이 true로 평가 되면 버튼이 비활성화됩니다.
<p>
<button disabled>Click Me!</button>
</p>
mySwitch 의 값이 false로 평가 되면 버튼이 비활성화되지 않습니다.
<p>
<button>Click Me!</button>
</p>
예제소스
<!DOCTYPE html>
<html>
<script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.6.4/angular.min.js"></script>
<body>
<div ng-app="" ng-init="mySwitch=true">
<p>
<button ng-disabled="mySwitch">Click Me!</button>
</p>
<p>
<input type="checkbox" ng-model="mySwitch"/>Button
</p>
<p>
{{ mySwitch }}
</p>
</div>
</body>
</html>
AngularJS는 응용 프로그램 데이터를 HTML DOM 요소의 속성에 바인딩하기위한 지시문을 가지고 있습니다.
ng-disabled 지시어
NG 장애인 지시어는 HTML 요소의 disabled 속성에 AngularJS와 응용 프로그램 데이터를 결합한다.
예
<div ng-app="" ng-init="mySwitch=true">
<p>
<button ng-disabled="mySwitch">Click Me!</button>
</p>
<p>
<input type="checkbox" ng-model="mySwitch">Button
</p>
<p>
{{ mySwitch }}
</p>
</div>
신청 설명 :
NG 장애인 지시자는 애플리케이션 데이터 바인딩 mySwitch 는 HTML 버튼의에 사용할 속성을.
NG 모델 지시어의 값으로 HTML 체크 박스 요소의 값 결합 mySwitch을 .
mySwitch 의 값이 true로 평가 되면 버튼이 비활성화됩니다.
<p>
<button disabled>Click Me!</button>
</p>
mySwitch 의 값이 false로 평가 되면 버튼이 비활성화되지 않습니다.
<p>
<button>Click Me!</button>
</p>
예제소스
<!DOCTYPE html>
<html>
<script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.6.4/angular.min.js"></script>
<body>
<div ng-app="" ng-init="mySwitch=true">
<p>
<button ng-disabled="mySwitch">Click Me!</button>
</p>
<p>
<input type="checkbox" ng-model="mySwitch"/>Button
</p>
<p>
{{ mySwitch }}
</p>
</div>
</body>
</html>
게시판 목록
퍼블리싱강좌
| 번호 | 분류 | 제목 | 글쓴이 | 날짜 | 조회 |
|---|---|---|---|---|---|
| 148 | AngularJS | 8년 전 | 1653 | ||
| 147 | AngularJS | 8년 전 | 1070 | ||
| 146 | AngularJS | 8년 전 | 1255 | ||
| 145 | AngularJS | 8년 전 | 1369 | ||
| 144 | AngularJS | 8년 전 | 1154 | ||
| 143 | AngularJS | 8년 전 | 1201 | ||
| 142 | AngularJS | 8년 전 | 1170 | ||
| 141 | AngularJS | 8년 전 | 1330 | ||
| 140 | AngularJS | 8년 전 | 1196 | ||
| 139 | AngularJS | 8년 전 | 1439 | ||
| 138 | AngularJS | 8년 전 | 1149 | ||
| 137 | AngularJS | 8년 전 | 1060 | ||
| 136 | AngularJS | 8년 전 | 1149 | ||
| 135 | AngularJS | 8년 전 | 1673 | ||
| 134 | AngularJS | 8년 전 | 1379 | ||
| 133 | AngularJS | 8년 전 | 1472 | ||
| 132 | AngularJS | 8년 전 | 1098 | ||
| 131 | AngularJS | 8년 전 | 1367 | ||
| 130 | AngularJS | 8년 전 | 1463 | ||
| 129 | AngularJS | 8년 전 | 1437 | ||
| 128 | AngularJS | 8년 전 | 2060 | ||
| 127 | AngularJS | 8년 전 | 1483 | ||
| 126 | jQuery Mobile | 8년 전 | 2256 | ||
| 125 | jQuery Mobile | 8년 전 | 2013 | ||
| 124 | jQuery Mobile | 8년 전 | 1881 | ||
| 123 | jQuery Mobile | 8년 전 | 1811 | ||
| 122 | jQuery Mobile | 8년 전 | 1851 | ||
| 121 | jQuery Mobile | 8년 전 | 2056 | ||
| 120 | jQuery Mobile | 8년 전 | 1592 | ||
| 119 | jQuery Mobile | 8년 전 | 1674 |
댓글 작성
댓글을 작성하시려면 로그인이 필요합니다.
로그인하기