This website recently got a major rebuild; if you're missing something, let Lorna know.

    Category: php


  1. My Book is Published: PHP Master


    PHP Master Cover ShotI 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.

    Read more

  2. Announcing Training Dates for November


    I'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!

    Read more

  3. ArrayAccess vs ArrayObject


    I help people qualify for Zend Certification and in the last few months I've had questions about both ArrayAccess and ArrayObject. This post is an attempt to illuminate both.

    Read more

  4. At the Helm of Joind.in


    As of a few days ago, and following Chris' post, I am now the proud owner of an open source project.

    Read more

  5. Learning About Web Services


    I'm updating my web services tutorial session at the moment for the PHPNW Tutorial Day. I switch the order of the topics around every time, in an effort to make it more digestible, and I thought I'd share.

    Read more

  6. PHP OAuth Provider: Access Tokens


    I've been working with OAuth, as a provider and consumer, and there isn't a lot of documentation around it for PHP at the moment so I thought I'd share my experience in this series of articles. This relates to the stable OAuth 1.0a spec, however OAuth2 has already started to be adopted (and differs greatly). This article uses the pecl_oauth extension and builds on Rasmus' OAuth Provider post. This entry follows on from the ones about the initial requirements, how to how to handle request tokens, and authenticating users.

    Read more

  7. PHP Static Analysis Tool Usage


    Last week I tweeted a poll with the question "Which PHP static analysis tools do you regularly use?". These are the results:
    Static Analysis Tools Poll Results (phpcs 81%, phpmd 59%, phpcpd 59%, phploc 41%, phpdpd 48%)

    My interest was mostly because I'm working on a book chapter which includes some static analysis content, and there are a couple of these tools that I include …

    Read more

  8. Shortening URLs from PHP with Bit.ly


    I've been looking around for a really simple API that would be a nice place to get started using web services from PHP - and I realised that bit.ly actually fits the bill really well. They have straightforward api docs on google code, and it's also a pretty simple function!

    Here's a simple example, using PHP's curl extension, of using the bit.ly API to get a short URL, using PHP (you need an API key, but if you're a registered bit.ly user, you can log in and then find yours at http://bitly.com/a/your_api_key).

    Read more

  9. PHP Returning Numeric Values in JSON


    When I wrote about launching a prototype of a new joind.in API, quite a few people started to try it out. My friend David Soria Parra emailed me to point out that many of the numbers in the API were being returned as strings. He said:

    It's just a …
    Read more

  10. PHPMyAdmin Designer View


    This week I've been using phpMyAdmin for what feels like the first time in years. I'm happier at the command line, but needed some graphical representation of information and easy ways to export example queries for the book I'm working on. I noticed that phpMyAdmin now has a Designer tab, which shows relationships between tables and allows you to define them.

    |image1|

    Read more

  11. Gearman Priorities And Persistent Storage


    I have been writing a bit about Gearman lately, including installing it for PHP and Ubuntu, actually using it from PHP and also how I use persistent storage with Gearman. I'm moving on to look at adding jobs of different priorities.

    I use Gearman entirely as a point to introduce …

    Read more

  12. The Strpos Trap


    This week I found myself again using strpos as an example of the difference between the == and === operators in PHP. The strpos function tells us where a string occurs within another string, by returning the character offset. If the string isn't found, then the function returns false.

    The problem arises …

    Read more

10 of 27