A minor update with a couple of bug fixes, a handful of tweaks, and some small niceties added.
After much delay comes the new update. I’m not extending the functionality at this point but making some tweaks and fixing some of the small bugs. You can grab it from the main page: Lightbox JS v2.03
- Object and Embed elements hidden on Lightbox activation, prevents Flash movies and other media from appearing through Lightbox image
- extended keyboard support (arrow keys, esc key)
- added toggle in Javascript file to turn off animations
- imagemap support
- valid CSS
- clicking anywhere in ’shadow’ closes Lightbox
- removeDuplicates function works with incontiguous items
- a bit of code cleanup
Like I said, minor stuff.
AsceticMonk Apr 16th, 2007
Thanks for the update! Good addition on the extended keyboard support, and also happy to know that CSS is now valid!
Jasper Apr 17th, 2007
Thanks for the update.
Keep up the good work!
Ankur Apr 17th, 2007
Nice work, Lokesh Bhaia!
Although I like mootools better than prototype :)
Keyboard Cowboy Apr 17th, 2007
Thanks! I was just about to use this again, and I almost went to my cache of files to grab it. Glad I checked here today!
Thanks again.
sinder112 Apr 17th, 2007
Is there a way we can embed videos? Or will there be in future releases?
Lokesh Apr 17th, 2007
#5 sinder112
Sorry, photos only. For other content, google for Lightbox modifications or try an alternative script such as ThickBox or Lightwindow.
Raige Apr 17th, 2007
I really like this script, it looks great and at the transitions are so smooth that at first I actually thought it might be flash. However, I notice that if the image height is larger than that of the browser window, once the image loads, the overlay does not cover the newly scrollable portion of the window in Internet Explorer (it’s fine in FireFox and like browsers). This also occurs upon resizing window height from a smaller to larger window while the image is open (in several browsers).
Brendan Apr 17th, 2007
Thankyou Lokesh for continually improving upon one of the best website enhancements available …
sinder112 Apr 17th, 2007
Thanks for the information. Your work is amazing.
anas Apr 18th, 2007
the update is not that tiny compared to how small the script is.
ArielAleXCo Apr 19th, 2007
I liked the version 1 and I loved the version 2, haven’t try this yet, but… er… Just one little little cuestion ive been trying to figure out by myself but haven’t been able to find de answare (since version 1)….
Is there a way to make the FULL IMAGE be viewable while downloading???
oh yeah… another one, sorry… er… I read almost everything on the forums, faqs and that stuff,… but is there a way to make work “on click” and not in “until everything is loaded “??? :S
Thanks for this great code ^_^
Nigel Apr 19th, 2007
Just started using Lightbox. It’s great, but we’re having problems using it in IE6. It starts to work and then crashes. Any thoughts as to why?
Cheers – N
Lokesh Apr 19th, 2007
“but is there a way to make work “on click” and not in “until everything is loaded “???
ArielAlexCo: There are methods to execute javascript before images are finished loading. They allow you to run your script after the DOM has been initialized but before the rest of the page dependencies have completed loading. For further reading:
brothercake’s domready function
Peter Apr 20th, 2007
Great little feature but being a dummy I cannot install it. Any chance someone can send me an email at peterphillips77@hotmail.com on how to install this great Lightbox2.03, ie. very simple and clear instructions PLEASE?
cheers.
Peter
Tim Apr 20th, 2007
I like the plugin very mucb, but since I updated to 2.03.1 I am having a few problems. In Safari, at least, a “?” appears where the “close” image should be in the bottom right hand corner of the lightbox. The “close” image is being called but not found.
In Firefox the lightbox has an extended whitge area to the bottom, double the size of the image, the image shows but width an oversized bottom white border.
Any suggestions?
Tim Apr 20th, 2007
Fixed. I had to respecify the location of closelabel.gif and loading.gif with full urls. I still have oversized lightbox whitespace however with one wordpress theme (Island After Sunset) in Firefox. Puzzling …
Joseph Apr 22nd, 2007
Thanks for the update, keep up the great work.
joe
ArielAlexCo Apr 22nd, 2007
O_o ?? ok…. i’ve cheked the site, download… i bealived instaled, but didnt understood the DOM, XDD jajjaa, ok. thanks. So, user should wait for complete download XDD.
Thanks, for you time and codding, I’vve already tried the 2.03 version and it was easier to customised it, a really liked the upgrades ^_^
;;;;; Apr 22nd, 2007
;;;;
Antoine Apr 24th, 2007
Very good script !!! But … i have a question …
How to center the lightbox on my page ? I’m a newbie and i’d try
to change parameters in the css file and i’dont succed !
Could you help me … ?
I just want to have a lightbox which open at the center of my web page.
Thanks a lot.
Antoine.
vitto Apr 24th, 2007
hi, is it possible to load dynamic content in the modal window, ie a product details from a mysql db (both text and pics)?
Thanks
Great work by the way
Parvinder Singh Apr 24th, 2007
I am trying to use this script along with a Slideshow (as my header banner). Now I have used command “ONLOAD=”runSlideShow();” ” in my body which is not allowing this script to run. If I remove ONLOAD command, the script works fine.
Is there any solition where I can use both together …..
thanks in advance
THoL Apr 24th, 2007
Whenever I discover a new way of doing something cool I just think ‘wow’, Lightbox gets a ‘WOW’. You’re doing some great stuff, and deserve the praise.
fjordan Apr 24th, 2007
I’m running into a very weird problem, no matter I’m using lightbox v2.01 or 2.03.1. Lightbox is only functional when the page is initially loaded.
Let’s say I have all images embedded in a …. 10 images inside this div, here… >
I use Javascript to dynamically replace the innerHTML contents of this wrapBox div.
As soon as this div is replaced with another 10 images, all lightbox effects are gone. And I know for sure, there is nothing else being changed on this page, I assumed all javascripts loaded should stay effective.
Besides, all rel=”lightbox” are associated with the anchor… href thing…
Any idea, folks???
fjordan Apr 24th, 2007
A follow up on my previous question:
lightbox.js basically invokes: initLightbox() as window.onload is fired off.
That’s why when I dynamically changing content of a div, basically all contents are images to be shown in the lightbox-ed way, the lightbox isn’t effective.
I’m not exactly sure how this can be tackled, in the era of Web2.0 and everything is AJAXized, it’s definitely necessary to have lightbox to support dealing with a scenario as this ;-)
-fj
Anonymous Apr 25th, 2007
Well, after a few hours of hair-pulling, now I finally got the point.
As the innerHTML content is dynamically rendered by AJAX (XHR HTTP GET return contents), a reasonable delay has to be set before invoking initLighbox()
so after XmlHttpGet() and div innerHTML value set,
invoke this:
setTimeout(“initLightbox()”, 500); // set a 500millsecond timeout before invoking initLightbox() this way we hope the content has stabilized or available to the browser/client-side…
Also, make sure:
1. comment out Event.observe() line (the final line), this is useless now.
2. wherever you invoke window.onload = function() {….}
make sure initLightbox() is called as well.
that’s it.
cheers.
-fjordan
Nirav Apr 25th, 2007
Thanks for the wonderful script!
installed and working in under 30 minutes!!! All thanks your great documentation.
Have two questions though…
1) the images for next and prev don’t always show up; kinda sporadic as to when then do. Its odd since the “close” image does. Haven’t test the “loading” image since it is on my local machine loads really quickly.
2) Under the close button is it possible to add another container for comments? and a form to submit comments?
Thanks again for the great work!!!
April Apr 26th, 2007
Can’t wait to see it^^ thanks you so much!!!! for lifting my burden.
Rock On!!!
john Apr 29th, 2007
hello
can I increase the size of the image?
I woulf like to have a bigger photo..is this possible?
thanks a lot
Rafael Apr 29th, 2007
John, if the size of the image is increased, it will pixelate and look horrible. If you want the picture to be bigger, that’s your responsibility, not the writer of this script’s!
posttoast Apr 29th, 2007
This is great stuff!
One thing though: I would like to place all navigation (previous/next/close) at the bottom of the lightbox. What is the easiest way to do this? Maybe someone else here already did this?
cWanja Apr 29th, 2007
Wouldn’t you just adjust the CSS to align the images at the bottom of the picture?? Be careful though posttoast not to override the next image on top of the close image.
Patrick Apr 30th, 2007
I love your lightbox! I want to be able to display flash inside of it for the motion graphics section of my portfolio. I was wondering if this was possible or might be possible in the future. Thank you!
Adolfito121 Apr 30th, 2007
First Of all, thanks for that great utility.
I’m testing it to put on my website but when the embedded image is a moving gif it doesn’t works propertly on Internet Explorer and In Opera (but it really works fine on Firefox).
Thats the url:
http://xarcuteria-olive.com/Pruebas%20web/index.htm
and the animated photo is the 9th(4th, 5th, 6th, 7th and 8th are still to be uploaded).
posttoast Apr 30th, 2007
@ cWanja: I wish it was that easy. It seems I have to edit the js-file as well, but I can’t get it to work properly.
Kenneth Apr 30th, 2007
The light box is great!!! How do I find the 2.03 version???
Lokesh Apr 30th, 2007
@24, 25, 56 – Re: Getting Lightbox2 to work with content that is added to the DOM after initial load.
A quick overview, once the page is loaded the lightbox script runs and searches for images that have the a rel attribute with a value of lightbox*. The script adds a click event handler to these images.
If you add images dynamically to a page after the initial page load you need to hardcode these click handlers . An example follows:
@34 Adolfito121 - It looks like the animated gif is refiring the onload event ever animation loop in IE. I will get a fix in for animated gif support by tomorrow evening.
@36 Kenneth - Added the link to v2.03 atop the post.
Adolfito121 May 1st, 2007
Thank you very much.!!!
Adeola May 1st, 2007
Hi Lokesh,
Does the end() method fire an event that I can watch for? For instance:
Event.observe(myLightbox, ‘end’, myCleanupFunction, false);
as I would like to call another function when I click the close button.
Thanks.
Ryan May 1st, 2007
Great utility! Finding more and more ways to use it and implement it.
Is it possible to add a link inside the window?
Leah May 1st, 2007
I think this is a great look! I’m a beginner at this and am working with Homestead Site Builder. I’ve tried to add an element and instert this code with my images but it’s not working. If anyone can help me please e-mail me at leah.parr@sonoco.com
Thanks!
Lampson May 1st, 2007
Hi!
Thanks! This is really great look! I tried to insert the code in my website, it works. However, there are some .gif file have same file names with others, so I created a new folder. Under this new folder, I copy and paste your files into it, then the scripts could not work. I tried to search the files and corrected them to a new location, but there is some .gif files could not showing, for instance, “prev.gif” , “prevlbabel.gif”. I want to know if it is the problem of the scripts of the head you provided, do I need to amend it as well?
Lampson
Till May 3rd, 2007
Hello Lokesh,
this is an awesome script! Keep up your great work. :-)
I’ve one suggestion …
Would it be possible to change the following hard coded lines into variable ones in order to configure the string “Image x of x” in the configuration area (at top of the script) comfortably for translating it in other languages:
// if image is part of set display ‘Image x of x’
if(imageArray.length > 1) {
Element.show(‘numberDisplay’);
Element.setInnerHTML( ‘numberDisplay’, “Image ” + eval(activeImage + 1) + ” of ” + imageArray.length);
}
More precisely: Only the string “Image” and the word “of” should be replaced by variables.
Because there were a lot of updates of Lightbox2 recently changing those strings inside the code is a bit inconvenient.
TIA!
Alessio May 4th, 2007
Thank you very much for this fantastic script!
Carbonize May 5th, 2007
There is a bug in Opera 9.2. If no title attribute is assigned to the link then Lightbox says null.
LightboxSupporter May 7th, 2007
Lokesh,
I feel so gutted.
Look at this : http://www.tomodo.net/PDOX.php
Read this line : “The website has simple pages and is the first to make use of the ‘Lightbox’ image gallery. (This also ended up being used here)”
It reads as if the guy did the Lightbox gallery, meaning he programmed it for his client. This is discrediting your effort!
I really feel gutted when I saw this.
Regards,
LightboxSupporter
Ardi May 7th, 2007
hi, great script!
is it possible to open the image always in the center of the browser win? if im horizontally scrolled to the right and open an image somewhere there, the big image still opens up on the left edge of the page, sometimes out of my screen…
thnx
A.
MMMila May 8th, 2007
This is very usefull and I learned lot of while put this script on my page!
But, it is good!
Thanx!
Lokesh May 8th, 2007
#39 Adeola – You could create a custom event and have both your cleanup function and the lightbox.end function subscribe to it.
#40 Ryan – You can add a link in the caption. (Instructions are on the Support section) If you want to add additional links, text, or images you will need to modify the script and have basic understanding of manipulating the DOM w/Javascript.
#43 Till – I will be releasing another update shortly w/a small Opera fix and in that release I will move the “image” and “of” strings into variables per your suggestion.
#45 Carbonize – Opera ‘null’ display fix should be up for tomorrow latest.
#46 LightboxSupporter – Thanks for catching this. Will email directly.
Msiagirl May 9th, 2007
Hi, great pics of Japan and Lightbox sounds like something I’d love to have on my blog. I am not a techie – only slightly geeky – and it doesn’t look like it works with blogger – is that right? Great application and good luck on it.
LAWRY May 11th, 2007
Hello, i am new to this JS and i have tried to get it to work but cant lol, can someone please email me easy but detailed instructions on how to install and upload files and so on, thank you
Lawry
lawrysdesigns@gmail.com
Brandy May 11th, 2007
How about an update to work with the latest version of Prototype (1.5.1)? Or does it already work?
You should at least consider it once the next final scriptaculous is released!
adolfito121 May 13th, 2007
Some minnor things. First of all thanks for that great script and for read us and update lightbox so soon.
I stiil can’t open an embbed gif in opera (the last update make it work on IE7, but not in Opera).
And I’ve changed the loading gif for another a litlle bigger with another image (my mom’s shop logo :S) and in IE7 it appears with the old size and Opera & Firefox shows the new loading.gif in the correct new size… guess that Microsoft works without respecting some web standars (?¿?)
That is the proving web that I’m doing
http://xarcuteria-olive.com/webcatala/index.htm
Have a nice day and greets from barcelona
Dirk May 14th, 2007
Love this script ;-)
Just one tiny thing:
on line 13 in v2.03.2 you give credit to Peter-Paul Koch whose site is quirksmode.com (not .org).
brendan May 14th, 2007
I’m having a problem with Firefox and Lightbox 2.03. (works fine in IE)
The part that drops down with “Image 1 of 20″ and the close button disappears after the animation ends.
This problem didn’t happen with v2.02
my site is here:
http://nadnerb.members.beeb.net/html/macro.html
here’s an image of the problem:
http://img503.imageshack.us/img503/2420/untitledgw7.jpg
Any ideas why this happens?
BTW, Thanks for this great script Lokesh!
Till May 14th, 2007
#55 brendan – These kind of problems are IMHO better placed in the forum: http://www.lokeshdhakar.com/forum
Your website isn’t valid “XHTML 1.0 Transitional”
http://validator.w3.org/check?uri=http://nadnerb.members.beeb.net/html/macro.html
and your CSS isn’t also:
http://jigsaw.w3.org/css-validator/validator?uri=http://nadnerb.members.beeb.net/html/css/bsp.css
It would be a good idea to fix that first.
And what about your class “opacityit”. Does it work correctly without this class allocated to the -tag?
You mixed your own CSS with the one of the Lightbox. There must be something in confusion … BTW Lightbox 2.03.2 had some minor changes in the lightbox.css since 2.02 (see also TOP).
HTH
Till
Till May 14th, 2007
#49 Lokesh – I love this script more and more … :-)
Just a few little tiny things:
(1) In v2.03.2 (line 5) there’s a little typo: “4/30/07″ (not “4/30/06″).
(2) You may point out in your support chapter
http://www.lokeshdhakar.com/projects/lightbox2/#support
the following PHP script: “Combine”
http://rakaz.nl/extra/code/combine
–> This script works great, but is only something for professionals. ;-)
(3) It would be really great, if Lightbox would work in the future with
Prototype 1.5.1 and Scriptaculous 1.7.1 (still beta)! – Especially
Prototype 1.5.1 should be allegedly very fast:
http://prototypejs.org/2007/5/1/prototype-1-5-1-released
Once again thank you for your incredible script! :D
Till
Andreas May 15th, 2007
Just like to say a big thanx! Great work – no probs at all, simple to tweak … just what I was looking for! Greets from good ol’ Germany
Andreas
brendan May 15th, 2007
#56 Till
Thanks.
As you can see, I have no idea what I’m doing with CSS! haha
I’ll try my best to fix it up and make it valid and if I still have problems with Lightbox I’ll post it in the forum.
Thanks.
Eugene May 16th, 2007
Having trouble. When click on thumbnail, open new page, full-size, no animation or shadow overlay. Followed the suggestion to modify the “
Erwan Corre May 19th, 2007
Thank you for your works : it’s a great project for webmasters and any one.
“C’est superbe !”
My exhibition with your script here :
http://www.erwan-corre.com/monde-etrange/index.php
Please continue !
Erwan
Klay May 19th, 2007
Really amazing work, thank you !!
A-Russ May 21st, 2007
Question from a novice user –
Is there any way to link to a folder with multiple pictures instead of linking every picture? My picture updates are usually 30+ pics.
Great product. very cool.
Artem May 24th, 2007
Hi, this is wonderful script.
I am trying to use Lightbox with IE 6.0 and I am getting IE notification bar with text “To help protect your security, IE has restricted this file from showing active content…” (I have default security settings). It is not a problem for me to click “Allow blocked content”, but some of my website visitors can continue browsing without doing that. In this case they will not see wonderful Lightbox effects :(
Is there any way to avoid that notification bar for IE users without asking them to click “allow blocked content”?
Giuseppe May 24th, 2007
SEI UN GRANDE!!!!!! Continua così!!
by italiana user
Kumi May 24th, 2007
Thank you very much for Lightbox! One thing I’ve got to ask though: Is Lightbox is all entirely Javascript? There has been a person fussing me over that what I’m using is DHTML and that there’s some sort of link to DynamicDrive that I should remove. I have no idea and I hope I am not defending myself blindly, but here: http://www.dynamicdrive.com/dynamicindex4/lightbox2/index.htm
we can see Lightbox on Dynamic Drive as DHTML. Can someone clarify this for me? Thanks in advance.
Nick May 25th, 2007
Wonderful piece of work.
I wanted to use this rightaway but I am already struck with UltimateTagWarrior for more than a week. As soon as that’s get resolved, I will install it.
Regards
Nick
Frank Jepsen May 31st, 2007
Lokesh Dhakar, thanks for sharing this wonderful tool with the rest of us.
You’re the man!
Heryos Jun 1st, 2007
Howe to import the Lightbox2 script in my flash site?
thanks
cagatay Jun 8th, 2007
hello. does it support auto slideshow?
Chris Bennett Jun 10th, 2007
Great work Lokesh,
Has anyone noticed that the overlay opacity isn’t working in ie6 in the 2.03 version of this excellent tool? Seems that the scripted transparency (instead of overlay.png as in the older versions) is causing a problem.
Fine in ie5.5, Firefox, ie7, Opera 9 etc only ie6
Cheers
Chris Bennett Jun 10th, 2007
Sorry meant to mention to Artem,
The warning will only appear on your local machine, web users won’t get the active x warning at all.
Cheers
Till Jun 10th, 2007
#71 Chris Bennett
IMHO you’re wrong. The demo reference website by Lokesh
http://www.lokeshdhakar.com/projects/lightbox2
with Lightbox v2.03.3 (5/21/07) does work perfectly and fine under IE6 (Win XP).
BTW discussions about these kind of problems are better placed in the forum:
http://www.lokeshdhakar.com/forum
Cheers
Till
Chris Bennett Jun 11th, 2007
#73 Till
Thanks Till,
It must be my standalone ie6eolas version not showing the opacity of the background for some reason – just needed comfirmation it was working for ie6 users and wondered if anyone had noticed a similar “problem” – the script was still working, only ie6 opacity of the overlay was ever an issue.
Thanks for the link to the lightbox forum – sorry for posting my question in the comments, simply hadn’t noticed the forum – please feel free to delete the unnecessary comments.
Cheers
Chris
user Jun 12th, 2007
hi
great script.
but if bitcoment is installed it breaks. seems like the download manager somehow conflikts with the script.
regards
Per-Gunnar Jun 13th, 2007
Excellent script. I am using it extensively on my site.
Many thanks for all your hard work.
Sofus Comer Jun 14th, 2007
Hi Lokesh and thanks for a great and clean solution to so many of us. I have implemented Lighbox 2.0.3 into my site http://www.fotomule.com and its a beauty until i reach the bottom of some of my portfoliopages. Then it goes totally ape by either not showing all the image and sometimes none. Maybe you or somebody can have a look and tell me if its a bug in lightbox or its my CSS thats doing this. I will happily send som files to be scrutinized if needed. Check out the page in question here: http://www.fotomule.com/portfolio.php?ID_serie=333&ID_fotos=4117&ID_usr=175
and go to the bottom of the page and click a picture and see what happens.
Take Care and thanks again.
Regards Sofus Comer, Photographer, Denmark
Manuel Jun 15th, 2007
Hello
I found this script fantastic and also liekd the Hoverbox from Nathan Smith. So i connected both and i find it great.
So take a look:
http://galerie.altherr.it
Have fun
Manuel
Roger Jun 16th, 2007
Hello, I love the script its easy to use. When viewing pics in the newest firefox it looks fine, IE7 the background shadow doesn’t cover all the way on the right side. I know very little about script and code.
http://www.batesfamilyohio.com
Volker Jun 17th, 2007
Thxs. for the script, just a little comment: When using lightbox, my site isn`t valid any more cause of the “duplicate specification of attribute “rel”". How can I solve this?
http://www.ayosnature.de
Regards, Volker
Goose Jun 18th, 2007
Hi, first of all i love the new version is great. I am having a lil problem getting the close image to come up in both ie and ff can anyone help me out. it comes up with a box crossed out in ie and nothing in ff and the white bit at the bottom is tiny in ff too.
Cheers
Goose
Montoya Jun 19th, 2007
Nice job!!!
http://andymontoya.com
Jeff Jun 20th, 2007
Nice Work,
But, it’s possible to make an update what allow lightbox in iframes?
Tiff Jun 20th, 2007
Hi,
Excellent work. I used it and like it very much.
I also wanted to add more functionality like putting zooming effects by adding some zoom in out buttons. Can you tell me where I can add it to effectively acheive that functionality?
Aaron Jun 22nd, 2007
Love the script, beeen using it for a few months now.
I would like to move the buttons nav down to the bottom above the comment line. Also, is there any way to loop so when I get to the last picture, it will go back to the first one?
hellyes Jun 24th, 2007
nice nice nice :)
tobi Jun 24th, 2007
hi there,
does anyone has a STEP BY STEP tutorial for using lightbox in flash???i am a flash beginner and i am going to dispair of calling lightbox from flash…
i need help!!!
thanx a lot!
tobi
Scott Jun 26th, 2007
Found your Lighbox today, its absolutley awesome!
Deepa Jun 29th, 2007
This post was the answer to my prayer..
Thank you very much..
Here is where i have used your lightbox
http://earn-while-you-post.blogspot.com/
Cliking in the images… the pic is enlarged in light box ( Superb)
However i have a query…When the mouse is moved over the image.. i would like to have the zoom cursor to appear.
After searching thro the default cursors ( arrow, crosshair,etc etc) i decided to make my own as say zoomin.ani ( even though it has the extension of a animated cursor.. it has a single frame and appears as a static cursor)
I tried adding the cursor(url of zoom.ani) to the img tag ( and also my template).. yet.. when i view my blog in browsr ( IE & FF)… the zoom cursor fails to appear.
…Could you please take a look and let me know as to how to get this zoom cursor working
..the reason why i want the zoom cursor on the image.. is … to tell the viewers that the pic can be zoomed in (.. in normal case the hyperlink appears and opens the pic as url)
nabizan Jun 29th, 2007
Hye guys
have y seen what have done google in his ‘picasa wab albums’?
something unbieleble! when y create your own album and upload a few photos, then click on edit my album and … incredible popup will turn on, something amazing. I have been working on similar functions but its will take much more time than i expect, and if I take a look how it could look like … something like that i always wish to my web page, i have been dream about it for a long time SIMPLE AMAZING. And if there is anybody who have much more free time than me and it like him it could be NEW RELEASE under lightbox. (I expect they simply take latest version of this one and modified it to theirs)
Fabio Jun 30th, 2007
Superb piece of code, Lokesh, congrats!
One question, though: is it possible to call it from within a flash swf? If so, please leave some instructions… I’m not exactly a web savvy!
All the best,
Fabio.
Vincent Jul 2nd, 2007
Lokesh, you’re amazing, my online photoalbum is been pimped.
Diego Jul 3rd, 2007
Excelente ejemplo, y muy aplicable; Gracias por ayudar a los que apenas empezamos en este mundo del web.
FEIHONG_CHN Jul 5th, 2007
THANKS FOR YOUR GREAT JOB!
I MAKES MY WEBSITE SO BEAUTIFUL!
okaydave Aug 18th, 2007
This is a great script and I’m going to use it throughout my site.
I know this is probably possible but an amatuer like me can’t figure it out. Is it possible to show the ‘close’ button above the image instead of below it? Some of my images are quite large, and I don’t want visitors to have to scroll down to find the close button.
Mark Aug 23rd, 2007
First of all.. THIS IS FREAKIN’ AMAZING.. I love it!!
I love version 2 because of the ability to make grouped image sets.. Does anyone know of a modification available that will allow the “PREV” and “NEXT” buttons to be static?? I think it’s an amazing concept, but I think the average user won’t know where to find those buttons unless they find it by mistake..
Thanks so much for this great work..
HmongMe Aug 29th, 2007
My image gallery looks a lot better now. Thank you!
jmadden93 Aug 31st, 2007
Anyone know how to integrate some sort of “star rating” widget into lightbox (such as spotback.com)???
Lightbox + Spotback would be a killer way to view/rate photos on a blog!
Rowby Sep 3rd, 2007
Everyone loves the lightbox.
Any way I can add a print command, in addition to the “X” close command?
Thanks
Rowby
Galma Sep 10th, 2007
Hello,
it’s possible have two different lighbox.js file (with different name “lightbox1.js” lightbox2.js”) in the same page?
Thanks!
Crystal Sep 12th, 2007
I am interested to know if there is a way that allows the next buttons to automatically appear without a hover?
I find users may close the window in lightbox 2.03 before they realize they can view a group of images by clicking a next button once their mouse has hovered over the hot spots.
Cheers,
rory Sep 14th, 2007
I’m very interested in using Lightbox on my site.
However, it is interfering with the ability of people who use Internet Explorer (the browser that the vast majority of people use), to access my site. When they go to my page, with Lightbox 2.03.3 installed, the first thing they get is an alert sound and a pop-up saying: “In order to help protect your security, IE has restricted this website from running scripts or ActiveX controls that could accesss your computer. Click here for options…”
Then they have to click the pop-up, at which point another box comes up that explains the issue and gives them the choice of accepting or declining to access the site.
To access the site, they have to click yet again.
The result is that IE users are told that my site may be a security risk and they must click twice to access it.
This defeats the whole purpose of Lightbox, the principal benefit of which is that it enables people to see a photograph full size without opening a new page.
I realize that this is an IE issue and that it is not Mr. Dhakar’s “fault”, but the fact remains that Lightbox is an unattractive solution to the issue of displaying photographs unless the issue can be resolved.
I hope that this comment is taken in the constructive way that it is intended. If this problem can be fixed, I would love to use the programme, and I would also be happy to make a donation.
rory Sep 15th, 2007
To follow up on this, it came to my attention this afternoon that a gentleman involved in ZenPhoto has created a ZenPhoto theme that incorporates Lightbox.
For whatever reason, when one uses the current version of IE to go to this gentleman’s site, one does not get an IE security pop-up.
For info, see this thread on the ZenPhoto forum: http://www.zenphoto.org/support/topic.php?id=1705
rory Sep 15th, 2007
Well that is interesting. There is an IE problem when one is testing off-line, but it appears not to materialize when one goes on-line. That is good news. If this continues to be trouble-free, and if it’s the right solution for me as a design matter, I’ll be making a donation.
There is an interesting discussion going on about Lightbox from a design perspective here: http://www.37signals.com/svn/posts/592-been-lightboxed-lately
Cheers.
Wensheng Wang Sep 26th, 2007
For anyone who’s looking to add slideshow to lightbox. Please take a look at my post.
http://wensheng.com/blog/2007/05/22/lightbox-slideshow/
do a diff on lightbox.js and lightbox-ss.js and figure out what’s added (just a few lines). It’s pretty straightforward.
Levi Oct 29th, 2007
Horizontal Scrolling – overlay issue
Problem:
overlay anchored top left of web page instead of covering where you have scrolled too on the webpage.
Seems these guys/girls got it to work, using a totally different lightbox:
http://test.thecodecentral.com/demos/lightboxrev/lightbox.html
I myself prefer your version for the obvious aesthetic and functional features (image sets and transitions, although i really like their minimize/maximize feature, possible .4 update???).
Unfortunately my javascript knowledge prevents a solution. :(
Can you indicate where the “Support for horizontally scrolling pages.” is located in the 2.03.3 release?
maybe just post a link to a horizontal scrolling page that works with your lightbox???
here is my test site….. http://stu21o.com/v3s
all the thanks in the world! mjfav at aol.com
Brandon Bean Dec 6th, 2007
Is there a way to invoke Lightbox in the OnLoad command? I have a small html file that I would like to be displayed before the page without linking away. I am working on a site that is really buggy in Firefox, so I want a file to come up when the index page is loaded letting them know this and that they should view it in IE if they have any problems.
Is there a way to do this?
jorgegoyco Dec 13th, 2007
Very nice. Thanks for the update, and also including all the files in the download. You rock.
jorge
tahsin Dec 24th, 2007
verygood thank you very much
webber Jan 4th, 2008
Hey Lokesh,
Thank you for your great script….Just one question:
I am trying to apply your script on child element of IFRAME and on click the shadow effect only appear IFRAME CHILD page not on the PARENT frame element.
Would really appreciate if you can pass some tweak to solve this…btw just clicked on forum link got “page not found” – hope wasnt playing dumb!
Keep up the good work!
Moe Jan 5th, 2008
HI all!
Man this thing is great! I have it up on my test site at http://home.comcast.net/~tnavfd/index.html
I have a couple of questions:
Can I have it load a standard html page in the lightbox window? I have tried several different things but none has worked…
The second is along the same lines… I could use a pdf to show the same data (meeting minutes from the month VFD meeting). That would great to be able to show but if not I still tickled shitless by this script!
KODOS and GREAT Karma to you all!
I can be reached at moe@tnavfd.com if anyone wants talk off the blog… I have not joined the forum… thats hard for me to do with my work schedule and the fire / ems calls.
Happy New Year all! Moe
raj Jan 31st, 2008
hi,
I got your reference for lightbox2 from http://www.formula1.com/news/interviews/2008/1/7307.html#top and if you click on the images displayed here you will have the overlay images as with lightbox2. They might be using the same lightbox2. But there is some extra feature like Slideshow and PREV and NEXT button in the bottom. Is it possible with the default lightbox2 setup or we need to change something. Any information regarding this will be highly appreciated .
Thanks
zeppo Mar 2nd, 2008
Love the lightbox – just put it up without much problem.
Searched all over web. Similar queries unanswered:
Looking for code to loop last photo to first via prev/next buttons.
Thanks in advance,
zeppo
zeppo Mar 3rd, 2008
Google – Lightbox Slideshow – by Justin Barkhuff
Code adds loop and other finer controls
I’m so happy. Thanks alot. Oh, you’re welcome.
getho Mar 6th, 2008
mentioned several times, but is there a step by step for idiots to get lighbox working before the page finishes loading? I’ve seen this:
http://www.brothercake.com/site/resources/scripts/domready/#domready-fig1-after
is it necessaryu to hack the lightbox script, or can you just call lightbox in some way from the page code?
If you have to hack the script would it be the lightbox.js script? and what would you hack.
where does this go!?
var foobar = new domFunction(whatFunctionGoesInHere?);
Allahverdi Mar 19th, 2008
Hi Lokesh,
I really need to change images x of x words to other language, can u say me how can i do it?
Ozh Apr 3rd, 2008
FYI, I made this page to help find my way through all the lightbox clones and their various adaptations to various frameworks: The Lightbox Clones Matrix. Mucho thanks for creating this in first instance :)
clare Apr 6th, 2008
So just wanted to say thank you! I am seeing this everywhere now, and thought it was big of you to share. :)
Paul Apr 11th, 2008
Struggling to make Lightbox work with ruby on rails after an ajax call has refreshed my partial (complete with lightbox images). Any thoughts or fixes in the near future to combat this?
Luis Apr 21st, 2008
Hi,
I’m student and I’m going to use light box for one of my projects. I added the light box for the gallery sections and it works perfectly but I couldn’t find the way to add the “Next” and “Previous” links to the light box. I tried a few things in the css code, but they never work. Can anyone tell me what I should do?
Thanks very much!!
Navjeet Apr 21st, 2008
Hi very nice work
I have one question,,,how can i open a web page in lightbox instead of image
Thanks very much!!
Humberto Apr 28th, 2008
Dear Lokesh
I have a problem.
about some tall pictures – the overlay does not fit until the botton page.(IE6.0) A tray config the css (ovelay height – auto – but its fixed on 500px?), but dont work.
How can i do?
Humberto Carlberg
JH May 1st, 2008
I’ve found several possible ways to do this, but none have worked for me yet (I’m on Day 6). I have a bunch (over 30) thumbnails in a flash file and I’m trying to use Lightbox as a way for users to see a larger view. I’ve found and tried:
- Using a js Delegate
- FlashLightbox
- Lightboxinjector
I think simple is better, but none of these have worked. Too many buttons?
Can anyone suggest a sure-fire way to call Lightbox from a full screen Flash file? I’m not a coder, but I’m pretty good at cut-and-paste.
JH May 2nd, 2008
Here is the web site I’m trying to integrate with Lightbox:
http://www.hofmanstudios.com
The thumbnails are on the page called “The Table”
ARRRRGGGHHHH…
JH May 7th, 2008
All is good now. I got LightBoxInjector to work. I had to use V1.1 so I could control the transparency on a full page flash site.
StudioVizual May 22nd, 2008
Hei,
really great work, I am using lightbox for quite some time, but I havent noticed before that its doesnt work with IE6, at least not on any computer i tried.
For example:
http://www.studiovizual.com
Lightbox works great if I browse using Firefox, but as I said it doesnt work with IE6.
Dave Jun 18th, 2008
when I group the photos and it reaches the last in the group the next button still appears and when users click on it, it throws them into a neverending loading gif.
is there a way to turn off the next function on the last photo in a related group?
divesh Jul 13th, 2008
Hi Lokesh,
I used bluevoda and i used lightbox 2.30 example its working for only when i click on bluevoda preview for internet explorer but if i copy the code to another notepad for html extention its not working.
do i need to change anything or download anything
Chris Jul 26th, 2008
Hey Lokesh,
I’ve been having a problem with something minor.
I recently made a custom loading.gif file and replaced it with the default one.
Now whenever I click on a link that has the ‘lightbox’ attribute, the loading image seems like it has shrunken or gotten smaller.
Please help! ):
ram Jul 29th, 2008
i just added the LightBox script to a web page, in the live chat and it’s working, but…
when the LightBox closes, the page could not be refresh in FF
Does anyone know a way around this?
Safwan Ahmedmia Aug 16th, 2008
Thanks for the update mate, great work!
Safwan Ahmedmia | Multimedia Designer
http://www.ahmedmia.com
http://www.safwanonline.co.uk
Jonathan Provo Aug 17th, 2008
Hi,
I’ve added a gallery to my webpage about a week ago called MyGallery and I noticed they’ve used your Lightbox,, guess that’s why they’re not supporting me on that.
I must say, nice job! I have a small question though,, when opening a picture with the lightbox, the screen fades to black (the ’shadow’) and the lightbox pops up and shows the pic. But when you scroll down, the ‘new content’ on the screen isn’t shadow..
Here’s an online exemple, open up a picture, you’ll see what I mean(http://www.medisoc.be/comiteg/gallery.php). Is there a way to change/fix this or is this already happened? Cause the lightbox included in MyGallery is v2.0
Regards,
Jonathan
Solid Rock Design - Web Design Leicester Aug 19th, 2008
Excellent work, the Lightbox has been a great help with many of our web design projects, thank you.
Solid Rock Design | Web Design Leicester
http://www.solidrockdesign.co.uk/
hesashe Sep 8th, 2008
hi! how can i change the top margin.. or the size of the picture.. ’cause it did not suite in my frame.. for the reference please check my site.. and go to the gallery and find out my problem…tnx…
divelopers Sep 12th, 2008
Very nicely created plugin, going to share this page on my site :-).
Fernando Garcia Oct 9th, 2008
I added two lines to show the lightbox only when the user left-clicks on the image, i think that should be added as an option, since sometimes the users want to download the images.
updateImageList: function() {
this.updateImageList = Prototype.emptyFunction;
document.observe(‘click’, (function(event){
//added by F.
if(event.button===0){
var target = event.findElement(‘a[rel^=lightbox]‘) || event.findElement(‘area[rel^=lightbox]‘);
if (target) {
event.stop();
this.start(target);
}
}
}).bind(this));
},
Tested in firefox 3 , ie6, ie6, opera & safari…. hope someone finds it useful.
anonymous Oct 13th, 2008
Nice work! I Found this on the web yesterday: http://jquery.com/demo/thickbox/
Is this similar to yours?
Lushmind Oct 24th, 2008
L,
This is a great, elegant way to show images – much appreciated.
I was wondering how Lightbox would be tweaked so it worked horizontally instead of vertically – the Y-height as static while X-axis is scrolled. The shadow only extends to the original window size – (when I scroll right the shadow does not extend off screen). Also, the images always center themselves in relation to the the original position of the x-axis….so if I am scrolled right I have to go back to the left to see the overlay and the image.
Cheers,
t
Alex Nov 6th, 2008
Hi, i am having a problem here.
I am using Lightbox v2.03.2 and i have a page that grows up dinamically every day, but because of that dynamic growth, the image is not shown in the center of the browser win.
What should i do to center the image in the browser win having a page that grows up dinamically?
Mia Orantes Nov 17th, 2008
Does anyone know of a lightbox script or if this one allows users to save images to a personal lightbox then export their personal lightbox images to a PDF file or e-mail them?
I searched the forums and couldn’t find this question so I assume this lightbox script doesn’t have this feature???
THANK YOU… NEED HELP ASAP finding a suitable solution!!!
rtyucel Nov 26th, 2008
Hi,
thanks for this work. i wanna ask a question.
i have a ms access db and i am getting informations about images and i also want to count the hits of viewing of images. how can do i it? is it posibble?
Mrunal Dec 8th, 2008
Great work man… i just love it !!!
Umesh Kashyap Dec 18th, 2008
Hi Lokesh bhaiya
I am Umesh Kashyap new to web design can help to figure out this problem. when I use your lightbox style the result is not satisfying
The problem is that the lightbox showing in firefox at the bottom and in IE on top (not in the center of the screen)
please guide me I am very thankful to you.
I am already mailed you this problem with screenshots.
santosh Apr 20th, 2009
Hi Lokesh,
You have just great work… I needed a favour from your side it seems very small from your side when you just look into it…! I needed to add the aspect ratio to lightbox, i mean lightbox by defualt taking the orginal size of the image it has to take a predefined height and width for every image being displayed…! I did some changes but wasn’t happy with it…So, i felt like writing it down to you…! I look forward for your valuable support…!
Thank You,
Santosh
lawrence Jun 20th, 2009
Hi, Been using lightbox with nextgen gallery for a while and love it. I am just doing a blog with a theme that uses jquery/jcarousel but lightbox doesn’t like it. When one works the other doesn’t. I really need to solve this but frankly lack the know how. I really need help – my budget isn’t big but I could certainly pay a small fee.
Here’s hoping.
Thanks
L.
Renita Brummett Jul 31st, 2009
I set up a lightbox gallery and it works great but there is a difference in how the alt tags for the images are displayed from IE to Safari. In IE it only shows the small image alt tag but in Safari it shows the caption for the large image as the alt tag.
Is there anyway to change that? I would like only the small image alt tag to show.
thanks, Renita
James Aug 10th, 2009
This was wonderful to come across- our web developer wanted $850 for the exact same thing. Had a test page working in 5 minutes with your code by myself!
Thanks again!
needed a help Aug 16th, 2009
sir, actually i am using ur lightbox, in which i need to display a google map, using google map’s API, after clicking on a link, a lightbox shud open, n allow d user 2 view the map and go through it.
but when i tried, it just shows the loader. n nothing occurs !!
help me out pls.
Sheryll Aug 18th, 2009
Hi,
I just want to thank you for this wonderful script. I think this is the best script out of all the scripts available.
I just have a conflicting error which I hope you may be able to help me out with. It is between jquery script and your lightbox script. If you can email me, I can explain it in more details so I don’t disturb your other comments!
Thank you,
Sheryll
Giuliano Aug 19th, 2009
Very nice. Useful.
Simple, and beautiful.
Great work, man. Keep it up.
Matsing Sep 15th, 2009
This is a gr8 piece of code!
I’m having problems with showing multiple sets of images on one page. Is that even possible?
James Sep 26th, 2009
To make pictures popup from hotspots on an imagemap (ie from a link inside the tag) I found that I had to make the two small changes to lightbox.js described here: http://www.patworx.de/blog/?p=20 for cross browser compatability. Thank you for lighbox – great script.
Sandeep Sep 30th, 2009
I used this lightbox new version and its awsome but i want to add a transparent image over images that are i am showing through lightbox to secure images from thefting. is there any way to do so in lightbox or any other alternative.
Moby Oct 22nd, 2009
Hi, just want to say thanks for all the hard work, the lightbox feature on my site is making my life and those who view the photos so much easier.
rainbowPino Oct 22nd, 2009
Really thanks for all this wonderful work. Thank you.
I put together the visualization techniques with preview thumbnails Nicholls see here http://www.cssplay.co.uk/menu/lightbox.html , that I use for some time,
with the technique Lightbox2.
The problem is that the load time of the thumbnails is not immediate lasts a few seconds.
If during this time the user clicks on a thumbnail image is not part Lightbox2,
but the mere display of the image.
I also included the specification:
but nothing has changed.
I read all the comments on this page.
I have read almost all the comments on forums (wait for confirmation of registration).
But I have not found a clear answer to my problem.
Maybe just enter an image of loading. But the techniques I used do not work.
Someone could give me a hand (not very good at js).
thanks
Try! http://www.paliaga.net/test/light12/foto_2009.asp
Anonymous Nov 29th, 2009
Hello, I’m from Brazil.
Thanks for the update, this script is amazing and easy to use too.
Grateful.
Mathieu Parent Dec 18th, 2009
Hello Lokesh Dhakar,
As it is a bit hard to reach you, I’m leaving a comment here to ask you to change the license of lightbox from CC-by 2.5 to CC-by 3.0 (or another license). The current license is not considered free for the Debian project, and so lightbox can not be part of Debian.
Regards
Initial request: http://marc.info/?l=horde-dev&m=124524746519545&w=2
Anonymous Jan 13th, 2010
thank’s for your mind
gasaxe Jan 26th, 2010
Cool stuff, works great!
Brian Lane Jan 27th, 2010
We are very impressed with the work you’ve done with lightbox. It’s quite an impressive piece of work. Keep up the good coding.
Thanks,
Brian w/ propools.com
Anonymous Jan 29th, 2010
Thank you so much for this…this is a great tool and great job! Keep up the good work,. I will post my stuff up soon once I get the time to update my site….
I am form china?I love u
Pinging Feb 11th, 2010
None of the versions are supported on MasterPage and I was trying to embed my page inside a masterpage. Can u suggest a quick fix? I am new to Javascript
Pinging Feb 11th, 2010
Sorry Lokesh my bad. There was a script error on my page itself. Nothing to do with ur control. What excellent coding!!!