티스토리 뷰
jQuery 1.8 이상 부타는
두번째 파라미터에 다양한 오브젝 속성을 추가할수 있다.
$( "<div></div>", {"class": "my-div",on: {touchstart: function( event ) {// Do something}}}).appendTo( "body" );
Attribute values in selector expressions must follow the rules for W3C CSS selectors; in general, that means anything other than avalid identifier should be surrounded by quotation marks.
- double quotes inside single quotes:
$('a[rel="nofollow self"]') - single quotes inside double quotes:
$("a[rel='nofollow self']") - escaped single quotes inside single quotes:
$('a[rel=\'nofollow self\']') - escaped double quotes inside double quotes:
$("a[rel=\"nofollow self\"]")
'웹개발 > Jquery' 카테고리의 다른 글
| jQuery 잘하기 (0) | 2014.02.26 |
|---|---|
| 제이쿼리 페이지 플러그인 (0) | 2014.01.10 |
| jquery dragNdrop 구현 (0) | 2012.06.07 |
| jquery.Callback 소개 (0) | 2012.05.09 |
| jquery xml 를 ie가 파싱 못할 경우 . (0) | 2012.03.15 |
댓글