나는 AJAX를 통해 html로로드하고 DIV에 추가하지만 새로로드 된 html을 선택하고 hide()를 적용 할 수있게하려고합니다.)를 새롭게 추가 된 html의 요소에 추가합니다. 새로운 HTML은 내가 만 노드에 퇴색 할 수 있도록하려면 #comments에로드되는 경우새로 추가 된 노드 (jQuery)에만 효과를 적용하는 방법
현재 기능이
wall = new Object();
wall.showWall = function (options) {
// Use this to initiate the comment wall
$.ajax({
url: "activity_results.html?"+options,
cache: false,
success: function(html){
$("#comments .loader").hide(); // The wall's comment spinner
requestStuff.showResponse(); // Trigger the addComment function
if (!options){ // Make sure we are not paging
wall.showMore();
}
$("#comments").append(html).hide().fadeIn("slow");
}
});
}
같은 것을 보인다.
나는 $ ...에 대한 선택자로서 html 콘텐츠를 전달할 수 있는지 몰랐다. – psychotik
불행히도 효과는 이와 같이 적용되지 않고 즉시 추가되고 즉시 표시됩니다. – Simon
'html'은 무엇입니까? –