jquery 함수2 jQuery API 정복 - 클래스 제거, removeClass() .removeClass() 함수는 특정한 클래스를 요소에서 제거할 수 있습니다. 원문 링크 http://api.jquery.com/removeClass/ .removeClass( [ className ] )Returns: jQuery 개요 : 특정 조건에 맞는 요소 집합에서 한개, 여러개, 모든 클래스를 제거할 수 있습니다. .removeClass( [ className ] ) className 특정 조건에 맞는 요소에서 제거될 클래스 명 .removeClass( function(index, class) ) function(index, class) 함수에서 반환된 하나 또는 띄어쓰기로 구분된 그 이상의 클래스를 추가할 수 있습니다. Receives the index position of the eleme.. 2011. 3. 14. jQuery API 정복 - 속성 제거, removeAttr() .removeAttr() 함수로 요소의 속성을 제거할 수 있습니다. 원문 링크 http://api.jquery.com/removeAttr/ .removeAttr( attributeName )Returns: jQuery .removeAttr( attributeName ) attributeName 제거할 속성명 .removeAttr() 함수는 자바스크립트의 기본 함수인 .removeAttribute() 함수를 이용한 것입니다. 하지만 jQuery 객체를 바로 사용할 수 있고 크로스 브라우징이 되는 장점이 있습니다. 예 제 소스닫기 버튼을 클릭하면 disable 속성이 제거되어 text 박스가 활성화 됩니다. Enable 미리보기 버튼을 클릭하면 텍스트 박스가 살아납니다. .attr() 은 추가 .remove.. 2011. 3. 11. 이전 1 다음