SitePoint Sponsor

User Tag List

Results 1 to 2 of 2
  1. #1
    SitePoint Enthusiast
    Join Date
    Oct 2004
    Posts
    65
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Question re: lightbox/blockui type effect

    I have a single png image that is a rectangle with rounded corners and a little close window icon.

    I'd like this to popup and have the page behind dimmed out.

    Problem is that all the of the libraries available lightbox, blockui etc have their own elements/frames/close buttons.

    Do any allow you to turn all of this off, and simply popup a custom div but still dim the page out?

  2. #2
    SitePoint Enthusiast
    Join Date
    Oct 2006
    Posts
    88
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    If you just want a simple popup you can do this easily with your own div. Set the div initially to display none and either use a link that calls a javascript function that sets this to display block or add the function to the window onload.
    To dim out the back ground you will need to create another div element that sits a layer (Z-Index) behind the popup and has a color of black and then you need to set the opacity of the background - look at http://www.quirksmode.org/js/opacity.html for an idea.

    Unless you want to create image galleries I would recommend just doing this yourself without any hefty library.


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
  •