Results 1 to 3 of 3

Thread: Making Lightbox / Fancybox work with website

  1. #1
    Join Date
    Jun 2010
    Posts
    1
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Making Lightbox / Fancybox work with website

    Hi there. I am working on a website that unfortunately was required to be centered horizontally and vertically using margin: auto in the body tag. This, as expected, is causing real nightmares with Lightbox variants as the do not properly center on the screen. However, when I remote margin: auto or change it to margin: 0, it centers perfect. Can anyone help me? I've been pulling my hair out for days on this.

    Here's the code for the body:

    Code:
    body {
    	font: normal 12px/normal Arial, sans-serif;
    	color: #eaeaea;
    	background-color: #3D3A32;
    	width: 1100px;
    	height: 768px; 
    	position: absolute; 
    	top: 0;
    	bottom: 0; 
    	left: 0; 
    	right: 0; 
    	margin: auto; 
    	padding: 0px;
    	border: none;
    	}

  2. #2
    Join Date
    Jul 2010
    Location
    Denmark, Copenhagen
    Posts
    16
    Thanks
    0
    Thanked 3 Times in 3 Posts

    Default

    it should center when you do

    Code:
    margin: 0 auto;
    http://www.w3schools.com/css/css_align.asp
    Last edited by tomywie; 07-07-2010 at 10:02 PM.

  3. #3
    Join Date
    Aug 2014
    Posts
    1
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    More about....CSS Div on center

    darrang

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •