所以在我的div上加載了一些內容之後,我想初始化jscrollpane,但它不起作用。這是我的代碼。看看你們是否能告訴我什麼是錯的。JScrollpane不會在ajax後工作
阿賈克斯(jQuery的)
$("#mision").click(function() {
var id = this.id;
$.ajax({
url: template + "/acciones.php",
type: "POST",
data: "id=" + id,
complete: function() {
},
success: function(x) {
$("#cargaContenido").html(x);
$("#scrollpro").css({'height':(($(window).height())-361)+'px'});
$('#scrollpro').jScrollPane({
});
$(window).resize(function(){
$('#scrollpro').css({'height':(($(window).height())-301)+'px'});
$('#scrollpro').jScrollPane({autoReinitialise: true});
});
$("#scrollpro").trigger('resize');
},
error: function() {
//called when there is an error
},
});
});
現在做的工作!
仍然不工作:/ – Buff 2012-02-23 19:17:41
嘗試做淡入創建JScrollPane的後 – 2012-02-23 19:25:17
呀它不工作尚未:/ – Buff 2012-02-23 19:30:15