I started using Greybox for one of my web projects recently. I like it because it’s a little different that plain old lightbox.
BUT, there was a problem. In Firefox, after viewing a image and closing it, the back button would no longer work. The workaround was found by Jani at http://amix.dk/blog/viewEntry/19039
Hello,
Regarding the issue with the back button in Firefox, i think i found a solution.
First i came with this suggestion:
http://efrtw.spaces.live.com/Blog/cns!68A490680B58FBDC!139.entry
I did tweak the script a bit more, and now it seems to work fine in firefox.
Here is the new script for version 5.53:
The new gb_scripts.js file worked great!
Can you explain a bit what further modifications did you make? I am asking because I use modified greybox (from Russ’ Dev Space blog) and ‘Back button’ works now but after watching gallery on page I need to hit ‘Back button ‘ as many times as many images I watched to go back to ‘page-before-page-with-gallery.
Is there a chance that your modifications fixed this isse? :>
Regards
And another thing: download link to Your version of GreyBox isn’t working.
Dziureq,
The broken link should be:
http://myfreefilehosting.com/f/aeaad9cb1c_0.01MB
Sorry about that!
I didn’t do any of the modifications myself, I just used the one from this download. But doing a diff on the original and this one, I noticed that there were just some added checks to see which browser (IE or firefox) is being used. If it’s firefox, then the script just hides the iframe instead of removing it from the document.
It addition to this, I did change the line
this.overlay_click_close=false;
to
this.overlay_click_close=true;
So that the image popup will disappear when the user clicks outside of the image. Otherwise, the user always has to click on the “X” to close it.
I hope this helps, let me know if somethings unclear.
-Joel
When I use that script, my IE7 still shows the image on top of the page even though the main popup window is closed.
Glad that the modified script helped you, and thanks for the addition.
the link doesn’t work. can anyone post it again?
Yes it works in an acceptable way.
You can download it here:
http://www.megaupload.com/?d=HL0E7W7R