2016-01-23 130 views
0

坦克你!經過Ajax加載沒有點擊功能與jquery和bootstrap/Photogallery

我有一個新的問題AJAX負荷這個(ajax.php):

<div class="wall-img-preview lightbox clearfix"> 
<div class="wip-item" data-src="media/gallery/2.jpg" style="background-image: url(media/gallery/2.jpg);" data-sub-html="<em><h3>This is a caption heading</h3><p>Here goes the description...</p></em>"> 
<img src="media/gallery/thumbs/2.jpg"> 
</div> 
</div> 

但沒有點擊功能(圖庫與jQuery的swipefunction,引導等...)這是我的AJAX腳本:

$.ajax({ type: "POST", url: 'appajax.php', data: parameter, 
    success: function(data) 
     { 
     // $('#'+id).html(data); 
     $('#'+id).html(data).row("refresh"); 
     } 
    }); 

我嘗試與跳跳虎和刷新,但NU succsses :(請幫幫忙,謝謝!

回答

0

請糾正你的英語。

從我的理解,你的問題是後ajax負載吊頁面。請嘗試更換下面的代碼的代碼

$.ajax({ type: "POST", url: 'appajax.php', async:false, data: parameter, 
success: function(data) 
    { 
    // $('#'+id).html(data); 
    $('#'+id).html(data).row("refresh"); 
    } 
}); 

async功能將防止DOM得到掛起。

+0

嗨阿倫,我嘗試 頁面加載時,它的工作原理就不再適用於阿賈克斯更新範圍之後卻會所有,但顯示一個根無法打開照片 – mister32