我想从Ajax请求添加加载的HTML Div效果(例如向下滑动)。
我使用这个代码,但它并没有影响尚未:将Html添加到Div效果jQuery
obj.html(msg.d).show('slow');
这可能吗?
更新:这是我的全码:
$.ajax({
type: "POST",
url: options.webServiceName + "/" + options.renderUCMethod,
data: options.ucMethodJsonParams,
contentType: "application/json; charset=utf-8",
dataType: "json",
cache: true,
success:
function (msg) {
var html = msg.d;
obj.html(msg.d).show('slow');
// if specified make callback and pass element
if (options.completeHandler)
options.completeHandler(this);
},
error:
function (XMLHttpRequest, textStatus, errorThrown) {
if (options.errorHandler) {
options.errorHandler(this);
} else {
obj.html("error");
}
}
});
看看这个答案http://stackoverflow.com/questions/1520178/jquery-using-append-with-effects –
我写了我的代码从这个答案,但不工作。 – Shahin