altariamx2003
asked on
it is possible to make fancybox2 draggable?
I would like to know if it is possible to make fancybox draggable
I use this fancybox2 to open a new page to do something and when the user close the fancybox window it returns a value
this is the code:
My code works without a problem, but yesterday I found this amazing pluging: http://jquery.diaz-cornen.com/fancybox/index_dragfancybox.html
I tried to integrate to my code but it only works when I use a previouse version of Fancybox and this is a problem because "beforeclose function" only works for me in fancybox2
I found also that jquery ui has a jquery ui draggable but i cannot found any example about how to use it with fancybox
Thats way I was wondering if it is possible to make fancybox2 draggable
best regards
I use this fancybox2 to open a new page to do something and when the user close the fancybox window it returns a value
this is the code:
<script type="text/javascript">
var temporal;
$(document).ready(function()
{	
$(".various").fancybox(
{
maxWidth : 800, maxHeight : 700, fitToView : false,
width : '70%', height : '90%', autoSize : false,
closeClick : false, openEffect : 'fade',
beforeClose : function()
{
	 if($('.fancybox-iframe').contents().find('#lautor').val() != "")
	 {
	 document.getElementById('titulo').value = $('.fancybox-iframe').contents().find('#ltitulo').val();
	 document.getElementById('autor').value = $('.fancybox-iframe').contents().find('#lautor').val();
document.getElementById('lista').value = 1;
	 }
	 else { document.getElementById('lista').value = 0; } 	
}
});
});
</script>
<a class="various fancybox.iframe" data-fancybox-type="iframe" style="text-decoration:none;" href="buscar.php">
<input class="tabs" type="button" style="text-decoration:none;" value="Buscar"></a>
My code works without a problem, but yesterday I found this amazing pluging: http://jquery.diaz-cornen.com/fancybox/index_dragfancybox.html
I tried to integrate to my code but it only works when I use a previouse version of Fancybox and this is a problem because "beforeclose function" only works for me in fancybox2
I found also that jquery ui has a jquery ui draggable but i cannot found any example about how to use it with fancybox
Thats way I was wondering if it is possible to make fancybox2 draggable
best regards
ASKER
Why my question is neglected?
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
that didnt work
Are you using jQuery UI at all?
You mention it.
Don't know what beforeclose has to do with it?
You mention it.
Don't know what beforeclose has to do with it?
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
do you have an example about how to to use it with iframe fancybox that calls a page?
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
your idea is great, I gonna used with the galleries that I display using fancybox 1.X
unfortunately it didnt works with fancybox 2.x, but anyway Im gonna used instead jquery ui dialog
thanks anyway
unfortunately it didnt works with fancybox 2.x, but anyway Im gonna used instead jquery ui dialog
thanks anyway
ASKER