Block scroll when Lightbox appears - javascript

I use DOM window script for Lightboxes on my website. Is there any way to block scroll on main page when Lightbox appears and unblock when it disappears?
Or, maybe, you can advice better Lightbox script?
Thanks.

User this to disable or enable window scrollbar :
document.body.style.overflow="hidden";
on show your lightbox and
document.body.style.overflow="visible";
on hiding your lightbox.
but if your are really looking for a better lightbox library you can try this jQuery plugin :
jQuery Lightbox Plugin

Related

How to display image as an overlay while blurring the main browser window?

I'm looking for an example that shows how to display an image as an overlay in a browser while blurring/greying out the contents from the main browser window, here's an example...
http://fstopgear.com/product/satori-exp/view
Just click on any backpack image, then click any part of the browser to close the image..that's pretty much the functionality I'm looking for, I'm assuming there's a script or package that provides such control?
There are plenty of solutions as jQuery plugins for this. What you want is called "modal" or "overlay" window.
I recommend FancyBox: http://fancybox.net/
But also check out ColorBox: http://www.jacklmoore.com/colorbox
There are lot of solutions to get this done in jQuery. Please have a look into the following url's:
http://leandrovieira.com/projects/jquery/lightbox/
http://jquery.com/demo/thickbox/
http://fancyapps.com/fancybox/#examples

facebook like html lightbox

I am looking for a lightbox like effect script.
When click on a link or button, it will load the html/php file with the lightbox effect on the same page.
I know there are many such script available, but these scripts will have the pop-up form disappear whenever I click on the outer surroundings of the pop-up form. Is there any scripts that can have those pop-up forms remain when clicked on the outer section just like the ones on facebook?
Try the shadowbox script, you can download it at : http://www.shadowbox-js.com/
Colorbox would be my lightbox of choice: http://jacklmoore.com/colorbox/, although #julesanchez suggestion of shadowbox is an excellent choice as well.
This seems to be what you're looking for: http://davidwalsh.name/dw-content/lightface.php

Popping out images on transparent background Javascript

I was wondering how to get images similar to www.eskimodesign.com.au or facebook where you click on a photo and it pop outs and darkens the background.
(Try clicking on a project or image on the eskimo website)
You should check out
Lightbox
Fancybox
Thickbox
Slimbox
Check this out too: Rounding Up the Top 10 jQuery Lightbox Scripts
By the sounds of it, looks like you're looking for a lightbox component.
There are a lot out there each to their own design.
http://lokeshdhakar.com/projects/lightbox2/
You'll need to have jquery enabled while using this as well.
http://jquery.com/
Some other lightboxes
http://www.huddletogether.com/projects/lightbox/
http://fancybox.net/

lightbox + imageflow

I'm using imageFlow, and now i need to activate lightbox effect on the images.
Imageflow allow me to write the function onclick on each image, but how is possible to activate the lightbox effect without changing the whole script?
Thanks much
Simple solution, how to integrate the both modules: WordPress NextGen ImageFLow a Lightbox
In article is a part of code, which must be added to <head>.

JavaScript Image Popup Window

I would like to setup my gallery web page so that when a user clicks on the thumbnail image, a window pops up displaying a larger view of the image. I do not mean a pop up window as in a browser window but a window that is loaded within that same page and can be closed. I am not exactly sure how I would go about doing this. Any ideas?
See Lightbox2. http://www.huddletogether.com/projects/lightbox2/
If you can use jQuery I would recommend
Thickbox
These are also very good
Fancybox
Pirobox
Nyromodal
ImageBox
And a third option: jQuery Tools overlay
I believe the technique you're after is a lightbox (I think it was the first of these).
Thickbox is an awesome jQuery based clone, or there's about a million others out there :-)
Much advance option would be Magnific Or Gettopup

Categories