Lightbox is cool.

Posted in Coding, IT by Will on October 25, 2006.

Update: Use the Wordpress Plugin wp-lightbox to do all this (and more) for you automaticly.

Paul mentioned installing Lightbox today, and I decided to give it a go. I had heard of Lightbox before, but never thought of actually installing it on my blog - it’s fancy Web 2.0 stuff, and it surely would take a bit of effort to install, plus I’d have to stuff around with it for ages to make it work correctly. Well wasn’t I wrong… Seriously, it took less time to install Lightbox, and test that it worked, than it did to write the above portions of the post. Really. Steps for Wordpress (quick and simple, customise as desired): 0. Download Lightbox 1. Upload the content of the Lightbox zip file up to your wordpress directory - or - the root directory of your site (I chose the latter) 2. Open up wordpress directory/wp-content/themes/your current theme/header.php in your favorite text editor. 3. Insert these three lines somewhere between <head> and </head>:

<script type=”text/javascript” src=”/js/prototype.js”></script> <script type=”text/javascript” src=”/js/scriptaculous.js?load=effects”></script> <script type=”text/javascript” src=”/js/lightbox.js”></script>

(nb: If you installed lightbox in something other than the root directory, insert that in the src values above - eg src=”/wordpress/js/prototype.js”. I recommend using absolute links, rather than the default “relative” links given by the script, if you use virtual permalinks - i.e like I do: http://will.hughesfamily.net.au/20061025/lightbox-is-cool/) 4. (Only if you use the virtual permalinks) a) Open up /js/lightbox.js, and do a replace “../images with “/images (there’s two instances of it) b) Open up /css/lightbox.css, and do the same replacement (theres three instances this time) That’s it. Really. At most 2 minutes, if you’re on dialup, and type with two fingers. Now, For each image thumbnail you insert, add a link to the full size image, and put rel=”lightbox” in the anchor tag - so to get get an image to appear like so: Chatting after catching a ride. I would change this code created by Wordpress when I insert an image:

<a class=”imagelink” href=”http://will.hughesfamily.net.au/(snipped)/no-surfing.png” title=”Chatting after catching a ride.”><img id=”image115″ src=”http://will.hughesfamily.net.au/(snipped)/no-surfing.thumbnail.png” alt=”Chatting after catching a ride.” /></a>

to

<a class=”imagelink” href=”http://will.hughesfamily.net.au/(snipped)/no-surfing.png” rel=”lightbox” title=”Chatting after catching a ride.”><img id=”image115″ src=”http://will.hughesfamily.net.au/(snipped)/no-surfing.thumbnail.png” alt=”Chatting after catching a ride.” /></a>

Very cool… I can also do series too, like so:

<a class=”imagelink” href=”http://will.hughesfamily.net.au/(snipped)/no-surfing.png” rel=”lightbox[seriesname]“ title=”Chatting after catching a ride.”><img id=”image115″ src=”http://will.hughesfamily.net.au/(snipped)/no-surfing.thumbnail.png” alt=”Chatting after catching a ride.” /></a>

..for each image. eg: Surfing on the EisenbachChatting after catching a ride. Full credit to Lokesh Dhakar, who created Lightbox - it’s a very very easy to use set of scripts.

Hidden Imagery in Games?

Posted in Games, Teh Funnies by Will on October 25, 2006.

I’ve mentioned a few times before that I play Vox Imperium.

Today I joined a new game within Vox, and right above my base is … this:

Hidden Imagery in Vox Imperium - First evidence of an elephant-cow hybrid?
(click the image to open full size - Yeah, lightbox is cool - more info soon)

It looks like some sort of elephant-cow hybrid to me… freaky.

What other bits of hidden imagery (intentional or not) is out there?