hi friends i have i am showing some data via ajax on my page when ajax complete and i click on view info the colorbox is not working but i show the data without ajax and i click on the colorbox link its working and opening
why javascript is not working when data comes via ajax
thanks
$.ajax({
url: "remote.php?act=ShowContacts&id="+id,
cache: false,
success: function(html){
$("#displaycontacts").html(html);
}
});
$("#viewcontact").colorbox({width:"500px", height:"520px", iframe:true});
<a href="viewcontact.php?id=3" id="viewcontact" class="cboxElement">View Details</a>
when data comes from ajax and i click o the view Details colorbox is not working not opening but when i put this link without ajax its working fine