I know that a lot of the code doesn't use consistent quoting (because I wrote some of it so long ago). I'd prefer if you used single quotes around the string and concatenated the variables instead of including them in the string. It's a lot faster when PHP is processing the string.