Convert PHP arrays to short array syntax in seconds
Having just had to look this up, I thought I’d share how I did it. It’s really really easy. 1. Require code sniffer in your project (you are using composer, right?) 2. Run CBF using the DisallowLongArraySyntax sniff That will apply to everything in the current directory, so simply change the . to whichever specific […]
Copying theme options between Pantheon environments using WP CLI
One of my tasks today was to activate a new child theme on a project. We’d already migrated the site to Pantheon (using their very straightforward migration plugin) and had activated the parent theme – in this case Newspack – to start playing around. The Problem My colleague Bart had completed initial work on the […]
Remembering things is hard. Or is it?
As someone who has a terrible memory I was fascinated to learn about a method of Spaced Repetition via this amazing web comic-style thing. If you struggle to remember information, or just want a better memory, give it a go. Image credit: Image credit: Marco Verch
Learning by doing, and more…
Last night my brain interrupted my enjoyment of Time Trap to make me ponder why I’m not particular motivated to learn new things. When there’s so much New to learn in web development all the time, it’s pretty important to keep up, but I haven’t been feeling up to it. Thankfully I remembered that I […]
Sabbatical day 1
Yesterday was the first day of my 3 month, fully paid sabbatical. It’s a perk I’ve received, liked many others, for working at Automattic for five years. This sabbatical actually became available to me way back in November 2018 but due to poor planning and then the pandemic hitting it’s only now that I’m taking […]
Why is public money being doled out to politicians in Lichfield?
This week, Lichfield District Council’s cabinet approved a pilot to hand £14,100 of public money to councillors to dish out at their discretion with a scintilla of oversight that leaves the scheme wide open to abuse, in a step that seems to be a solution without a problem. In the report to cabinet, a lack […]
I’m building Newspack
As a freelancer at the time, contributing to Lichfield Live led to plenty of work in journalism from tiny startups like Hackney Citizen to established publications like Journalism.co.uk. I spoke at conferences and even once advised the regional editors at one of the UK’s biggest media publishers. Thanks to a recommendation, I won one of […]
RideLondon Training Update #1
Very nearly one year ago I joined a big family group to do the Memory Walk in Sutton to raise money for Alzheimer’s Society. We were walking in memory of my Dad who suffered from Pick’s Disease, a form of Dementia. We had a great time and smashed our fundraising target, generating over £1,000 for […]
TIL: array_push() is slow
Today I learnt (thanks Gary) that array_push() is actually kinda slow and it’s probably better to avoid it in most cases. There’s some (not very detailed but interesting nonetheless) tests in this StackOverflow answer.
The Bullshit Web, and some bullshit about AMP
Alright, let’s start off by saying that I’m definitely a little biased – part of my job involves working with the AMP team at Google and the fine folks at XWP on the AMP for WordPress plugin. I wanted to highlight some things about this Bullshit Web piece that’s going around, though. In short: the […]