0
이 스크립트는 jQuery 1.9에서 작동하지만 1.8에서는 작동하지 않습니다. 이 스크립트를 jQuery 1.8로 변환하는 방법은 무엇입니까?스크립트를 jQuery 1.9에서 1.8으로 변환
HTML
<div id="container">
<div id="c1" class="aaa" style="text-align:right; color:red top:100px; ">child 1</div>
<div id="c2" class="aaa" style="text-align:left; top:200px; ">child 2</div>
</div>
jQuery를 스크립트
$("#container").children().each(function() {
alert("element ID = " + $(this).attr('id'));
var styleProps = $(this).css(["width",
"height",
"color",
"background-color",
"text-align",
"left",
"top",
"right",
"bottom"]);
$.each(styleProps, function (prop, value) {
alert(prop + " = " + value);
});
});
는 http://jsfiddle.net/ynternet/tzEHe/5/ -. 그것은 – Patrik
:(일을 다시는 내 대답을 읽기하지 않고 배열을 허용하는 CSS 기능은 jQuery를 1.8에서 사용할 수 없습니다 샘플입니다. 나는 괜찮은 작품을 제공했지만 실제로 사용해야합니다. –
죄송합니다. 당신이 맞습니다 :) 고마워요. – Patrik