Reputation: 753
I am using jquery click event to open fancybox and it is working perfect. I have added one textbox inside this inline1
div but when I input something I can't writer anything.
My Code:
$(document).ready(function() {
$(".fancybox").on("click", function() {
$("#inline1").fancybox().trigger('click');
})
});
jsFiddle: my code
Any Idea?
Thanks
Upvotes: 1
Views: 113
Reputation: 4177
$(".fancybox").on("click", function() {
$.fancybox($('#inline1').html())
})
check here
Upvotes: 0
Reputation: 4014
There was a problem with the triggering of 'click', I managed to fix this by simply using the Fancybox API to open the Fancybox without requiring a trigger.
$(".fancybox").on("click", function () {
$.fancybox.open( '#inline1' )
});
http://jsfiddle.net/xW5gs/1171/
Upvotes: 1