PHP archive

I have been working with the PHP language since early 2001, first as the nerdy hobby of a spotty teen and then later into my career as a Web Developer. I try to write about PHP things that will be useful to me, useful to you, and everything in between.

PHP Mail Form Updated

Version 2.1 of my basic free PHP mail form is now live; this has been ‘ported over from my personal domain (jemjabella.co.uk) in an attempt to organise my content (and life!) a little better. Please feel free to get in touch with feedback.… read more →

First PHP Game

Remember when I talked about wanting to code some PHP games? (Yes, it was in 2008, what’s your point?) Well I finally managed to fit one in to my busy schedule last week, whilst avoiding studying for my current OU module. Ignoring the fact that it’s talking about points (only relevant for the final ‘install’)… read more →

WordPress Child Pages Page… or something

OK, back to srs business posts now… One of my current top secret projects (it’s not that exciting, I’m just helping someone convert their site to WordPress) involves creating pages with a list of child pages on ’em. Back in ye olde days I’d have done this manually (which meant every time a child page… read more →

NinjaLinks Feature Requests

I’m being nagged for a NinjaLinks update ;) If you currently use the script and have feature in mind, please add your requests here. Can’t guarantee a date for release (for obvious reasons) but will fit it in when I can.… read more →

On Tumblelogs and Why I Love Habari

For at least 4-5 years I’ve been desperate to turn my blog into a sort of “tumblelog”; that is, a blog that consists of multiple content types that you can easily update with more than just full on text entries. The problem is, at first I lacked the know-how to achieve it — my early… read more →

24 Hours with Habari

So here we are, 24 hours after moving nearly 2 weeks worth of work (on and off) and it’s still standing. I’m impressed. :) Anyway, given that I know my conversion is generating a lot of talk about Habari and interest amongst you guys I thought I’d collect together some of my initial thoughts. Let’s… read more →

SQL Injection Flaw in FanUpdate

A security issue has come to light in FanUpdate (2.2.1 specifically but likely affects previous versions). This only affects those who are still running with register_globals turned on (a very bad idea). The problem — for those interested — lies in show-cat.php relying on an unsanitised $listingid. In an ideal world, show-cat.php should only be… read more →

Beginner’s Guide to PHP – Part Six

Functions are the lifeblood of PHP. You can’t do a lot without PHP’s built-in functions, and life would get very tedious very quickly if you weren’t able to define your own in a script. Let’s take, for example, one of my scripts: BellaBook. BellaBook is a flat file guestbook and so constantly writes to files.… read more →

| PHP

Beginner’s Guide to PHP – Part Five

Back in Part Four of the Beginner’s Guide to PHP, we covered the basics of arrays, and the foreach construct which is used to iterate over arrays. Today, you get to learn about for(), woot for you. According to the PHP manual, for() loops are the most complex in PHP, so I’m hoping I can… read more →

| PHP