You will recieve your password to this address. Address is not made public.

Your preferred username that is used when logging in.

Misplaced Overlay - Not centered Created Oct 27, 2009

This thread is solved

Views: 2314     Replies: 3     Last reply Aug 30, 2010  
You must login first before you can use this feature

michi20

Posts: 3

Registered:
Jul 8, 2009

Misplaced Overlay - Not centered

Posted: Oct 27, 2009

Hi all,

I have a problem with the position of overlays. I looked at the gallery module example and adapted it for my page. For my page both the overlay and the prev/next seem so work. But unfortunately the overlay is not placed in the center of the screen but say 2/3 on the right. Any ideas why this is the case?

Additional info: My page is generated by drupal and so contains deeply nested divs. Maybe this might be the problem?

wedoyou

Posts: 3

Registered:
Sep 4, 2009

» Misplaced Overlay - Not centered

Posted: Nov 20, 2009

Reply to: Misplaced Overlay - Not centered, from michi20
$("div.overlay").appendTo("body");

biapar

Posts: 1

Registered:
Nov 21, 2009

» » Misplaced Overlay - Not centered

Posted: Nov 21, 2009

Reply to: » Misplaced Overlay - Not centered, from wedoyou
Good tip!
Works

neokio

Posts: 2

Registered:
Jul 31, 2010

» Misplaced Overlay - Not centered

Posted: Aug 30, 2010

Reply to: Misplaced Overlay - Not centered, from michi20
My ajax loaded content was not centering until I did the following ...

$('#overlay_text').load('blah.php',function(){ $('#overlay').overlay().load(); });

... looks like using the callback lets the content load first, so overlay() can get an accurate content width/height. neato!