Results 1 to 4 of 4

Thread: Lightbox image viewer 2.0

  1. #1
    Join Date
    Feb 2007
    Location
    Pern
    Posts
    8
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Lightbox image viewer 2.0

    1) Script Title: Lightbox image viewer 2.0

    2) Script URL (on DD): http://www.dynamicdrive.com/dynamici...box2/index.htm

    3) Describe problem: My question is about using background images for the background instead of colors... I have my images displayed on a black background. I'm currently using it here: http://www.ozzgod.com/ozzfest06/main.html

    I ran across this page, http://www.bravewords.com/news/58235 that is using what appears to be the same Lightbox script, although I couldn't see a Dynamic Drive copyright when I viewed the source. Click on the image in the news story... it's using a background image with the Lightbox effect. I'd like to try this, too. Can I do this with the DD script and, if so, how?

    Thanks a lot in advance, guys...

    Leighton
    Last edited by ozzgod; 02-22-2007 at 08:23 PM.

  2. #2
    Join Date
    Mar 2005
    Location
    SE PA USA
    Posts
    30,495
    Thanks
    82
    Thanked 3,449 Times in 3,410 Posts
    Blog Entries
    12

    Default

    Lightbox is one of the few, perhaps the only DD script that does not require any credit on the page that is using it. This is as per the developer's say so as related to me by ddadmin. This is also reflected on the demo page where no credit is shown in the demo code.

    Anyways, the lightbox.css file is where you would probably want to go to use a background image. Experimentation may be required but, I'd try here:

    Code:
    #lightbox{
    	position: absolute;
    	top: 40px;
    	left: 0;
    	width: 100%;
    	z-index: 100;
    	text-align: center;
    	line-height: 0;
    	background-image:url(path/image_name.gif);
    	}
    - John
    ________________________

    Show Additional Thanks: International Rescue Committee - Donate or: The Ocean Conservancy - Donate or: PayPal - Donate

  3. #3
    Join Date
    Feb 2007
    Location
    Pern
    Posts
    8
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    thank you... thank you very much... I'll give it a try and let you know how it works...

    good to know about the copyright... I was wondering why it didn't show...


    Leighton

  4. #4
    Join Date
    Feb 2007
    Location
    Pern
    Posts
    8
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    ok...

    It didn't work where you had me place the background image, John. However, you did give me the courage to play around with it myself. I found that by placing a background image in two places in the lightbox.css file, the #outerImageContainer and the #imageDataContainer, I can get the effect I wanted... and that's really cool.

    This is what I did inside the lightbox.css file:

    Code:
    #outerImageContainer{
    	position: relative;
    	background-color: #000;
    	width: 250px;
    	height: 250px;
    	margin: 0 auto;
    	background-image:url(path/image_name.gif);
    	}
    Code:
    #imageDataContainer{
    	font: 10px Verdana, Helvetica, sans-serif;
    	background-color: #000;
    	margin: 0 auto;
    	line-height: 1.4em;
    	background-image:url(path/image_name.gif);
    	}
    I checked it in Internet Explorer 7.0, Firefox 1.8 and Opera 9.10 and works just fine in these browsers.

    Thanks again for your help. Like I've said, you guys rock...

    Leighton

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
  •