Can FancyBox be used on a button element?
document.getElementById("btn-dispos").addEventListener("click", function(){
$.ajax({
type: "get",
url: path_to_load_plages_dispo_fournisseurs,
data: {ids : ids},
success: function(data){
$('#btn-dispos').fancybox(
{type: 'ajax'},
fancyOptions
);
}
});
});
<button id="btn-dispos">Results</button>
I encountered the following error:
The requested content cannot be loaded. Please try again later.
Appreciate any help in advance!