-
Explaining MySQL's EXPLAIN
24 November 2011
Read moreThe MySQL explain plan is a great tool to help developers and database administrators to improve the performance of specific queries happening against a database. It is very easy to use, but its output can be confusing, so I thought I'd show a very simple example.
-
POSTing JSON Data With PHP cURL
22 November 2011
Read moreI got this question the other day: how to send a POST request from PHP with correctly-formatted JSON data? I referred to the slides from my web services tutorial for the answer, and I thought I'd also put it here, with a bit of explanation. After all, publishing your slides is all very well, but if you didn't see the actual tutorial, I often think they aren't too useful.
-
Handling SQL Errors in PDO
16 November 2011
Read moreI love PHP's PDO (PHP Data Objects) extension; it gives a consistent, object-oriented interface to handling all kinds of relational database backends. One thing that annoys me is that the MySQL driver for PDO defaults to a silent error mode which can make SQL errors tricky to spot!
-
Simple CRUD with MongoDB
10 November 2011
Read moreWhen I meet a new technology, I like to experience it "just as it comes". I'm happy at the command line and I like to type actual commands and see man pages before I use any wrappers or helper tools. So when I met MongoDB for the first time, I did exactly that. This post shows those first steps of creating a database, and inserting, reading, deleting and updating data.
-
Missing Kernel Source when Installing VirtualBox
09 November 2011
Read moreI'm creating a virtual machine to use for my upcoming training courses to get around issues trying to get machines set up in a hurry on the day. I haven't used VirtualBox before but since it has free clients for Windows/Mac/Linux I thought I'd give it a go.
-
API Serving JSONP
03 November 2011
Read moredisclaimer: I am not a client-side developer, and I don't write javascript. However I am committed to supplying useful APIs of all kinds, and JSONP falls into this category
Early in the development of the new Joind.In API, someone else started consuming the service to populate the javascript widgets they were making*. Since these scripts are intended to be used on many external pages, and they retrieve data from the joind.in API, cross-domain issues were a problem.
-
Flattr-y Will Get You Everywhere
01 November 2011
Read moreFor many years, I've been convinced that micropayments are the way of the future. The internet has brought us so much that is freely available, but often it's nice to show some appreciation for something someone has given us. This is true both for the open source software without which I couldn't do my job, and for the excellent content that makes me think or guides me through a particular issue.
-
PHPCon Poland: Conference Report
28 October 2011
Read moreAt the weekend (yes, this took all week to write), I was on my first ever visit to Poland, in order to speak at PHPCon Poland. They contacted me early in the year to ask if I would consider going along to give my talk Teach a Man to Fish.
-
My Book is Published: PHP Master
24 October 2011
Read more
I am truly delighted to announce that "my" book is published. Technically it's really "our" book since I had the pleasure of co-authoring with friends and PHP rockstars Davey Shafik and Matt Turland. The book is "PHP Master" and it's a broad-ranging text covering a series of topics that we felt were relevant to PHP developers who aren't beginners, but who are looking to fill in some gaps and get a good grounding in creating whole applications in PHP. -
UML Diagrams with Graphviz
18 October 2011
Read moreI worked on creating some plausible-looking diagrams for representing object inheritance (this is for my forthcoming book). Since I know I'll forget how I did it, I wanted to share while I can remember!
-
Announcing Training Dates for November
17 October 2011
Read moreI'm teaching some new public courses next month (in Leeds), so I thought I'd mention them on the blog in case anyone is interested. I'm super-excited because this is the first time I've delivered my own training content as a public course, so even if you aren't in the position where you work with lots of people who need the same training, you can pop along!
-
Ada Lovlace Day: Laura Thomson
07 October 2011
Read moreHappy Ada Lovelace Day! Today we celebrate geeky female role models, and I'm going to write about someone I consider a friend. It feels a bit strange to do so (and I didn't actually tell her beforehand), however having been written about before on this special day, I know I've never been offended by such flattery and so I hope she won't be either :)