ElePHPant

Posted on February 29th, 2008 in Random Thoughts | 3 Comments »

Well, a slightly less code-minded blog entry now just noting the hugely momentous occasion that is the arrival of my very own ElePHPant. For those not in the know, he's quite simply a plush toy version of the infamous PHP elephant logo. For tonnes of fun pics, you can take a look at ElePHPant on Flickr.

Here's a quick pic of my own ElePHPant reading a French book printed in the 1940s:
ElePHPant on Flickr

Right now, he's sitting atop the screen on my Macbook Pro, making sure I don't make any spelling mistakes. :)

P.S. Whilst we're on the not-so-serious side of posting, I finally upgraded to OS X 10.5 (Leopard) this week. I spent the best part of a day backing up essential files and documents only to have the installation process go super smooth without so much as a hiccup. Thanks Apple!

Adobe AIR out of Beta

Posted on February 26th, 2008 in AIR | No Comments »

Ok well maybe it's not very big news, but I've been playing around with AIR (formerly Apollo) for a while now; in particular the HTML/AJAX side of things more so than Flex or Flash. I've yet to produce anything that might be safe and wanted enough to release out on the big wide world, but I've made a few quick, little sample apps just to get a hold on the system.

Well today, the beta ended and the runtime is now ready for the world to start using. To run AIR apps you'll need the AIR runtime (like to view Flash you need the Flash runtime) but that's included automatically when you download your first AIR application -- of which there have been a bunch created already. You might have already used one if you're riding along on the Twitter bandwagon as a number of very good applications have been made to interact with that particular site/service.

Interested? Read more here: http://www.adobe.com/products/air/

PHP Imagecreate & Different File Types

Posted on January 22nd, 2008 in PHP | No Comments »

For a recent little bit of PHP scripting, I wanted to grab an image off of a remote server (not for any nefarious purpose!) and manipulate it in PHP (with GD). Read the rest of this entry »

PHP Get File Extension

Posted on January 13th, 2008 in PHP | 8 Comments »

Over time, I've seen a wide range of scripts which for one reason or another have had the need to grab the extension from a file name or path (E.g. "gif" from "mypic.gif"). Oftentimes the solution tends to fall back on what the task appears to need: string manipulation. Though, as you'll see, this may not be the best approach to take.

Read the rest of this entry »

PHP Variable Names: Curly Brace Madness

Posted on January 12th, 2008 in PHP | 5 Comments »

Most PHP coders will know that one is able to specify variable names in the following format, generally within double-quoted strings, however much they from on it:

$str = "Hello ${username}, you look nice today.";

However, that's not the only way to use the brace syntax!

Read the rest of this entry »