Another Lightbox hack

NOTICE
CONTENTS NO LONGER APPLICABLE

The content discussed in this post is no longer valid; as I’m now using a different “lightbox” implementation.
More here

When opening an image via lightbox, closing an image can get very counter intuitive. The close button is at the bottom right, which sucks if you have an image that’s larger than the viewing area. Trying to move that close button on the upper right can be too tedious as it requires a lot of modification on the DOM script and CSS. The easier thing would be to simply allow users to close the image when they click on it, after all, what else does one person usually do after viewing an image but close it right?

A hack for this is easy to do, however this usually broke Lightbox‘s “group” mode – instead of moving to the previous/next image, it prioritizes the close function assigned to the image container instead of the group mode’s prev/next overlays – resulting in the image closing anywhere you click.

The trick was to find another place where I could inject similar code, while making sure that it only does it when it’s viewing a single image. Read More

Eye-candy statistics

I was a bit bored a while ago, so I thought I’d just try to duplicate how this certain guy made his really cool pie-charts. There were so many comments asking how he did it even if they looked pretty simple to do (aside from having to actually conceptualize them of course). I even ended up making a template for it – for when I’ll use it (of which I have no friggin’ idea hahaha). In any case, just like the original guy did, I took information of visitors’ browser resolutions 1 I guess for the image to have some value however small – to prove that my decision to abandon 800×600 was the correct choice. from Mint’s Agent 007 pepper 2 A Mint plugin is called a “Pepper.”. I just did one chart though, since it was time consuming.

Notes

Notes
1 I guess for the image to have some value however small – to prove that my decision to abandon 800×600 was the correct choice.
2 A Mint plugin is called a “Pepper.”

How evil the RIAA is

On a more serious note, here’s a an audio sample of Ray Beckerman talking about the RIAA law suits. DefectiveByDesign.org, as it’s name implies is also against DRM 1 Digital Rights Management itself, on grounds that I will not discuss in this post. But the bigger issue of the RIAA suing innocent people is what’s being discussed. You can skip the introduction by Peter Brown and go directly to what Mr. Beckerman is saying (at about a minute and 47 seconds into the clip)

In case you need it, the transcript’s available here. If you live in the United States, please spread the word. Hell, even if you aren’t, spread it anyways. Digital copyright laws are bound to affect us one way or the other no matter where we live. Read More

Notes

Notes
1 Digital Rights Management