Climbing Ben Nevis for Survival International

I never post off-topic here, but this is a rare one-off in aid of charity. If you’ve found my posts here useful, please consider showing your appreciation by supporting my chosen cause.

On 1st June 2013 I’m doing the 11-mile trek up Ben Nevis to raise money for Survival International. Survival is the only organization working worldwide for tribal people’s land rights and human rights.

In my other life as an independent scholar I’ve been writing about indigenous cultures for a while now, exploring their spiritual beliefs and myths, and more recently examining the current debates about violence in indigenous societies and in pre-agricultural history. My forthcoming book expands on this research. I’ve decided to do something to more direct to support the ever-threatened rights of tribal peoples.

In the current economic climate, naturally everyone’s being squeezed. And while naturally I support the fight for greater equality in developed countries, I can’t help feeling that those at the very bottom of the scale of our modern vision of “progress” are going to be squeezed the most—and deserve extra support. Even as the supposed pinnacle of this scale, our own capitalist economies, teeter and founder, and continue to damage the environment, we try to convince ourselves that people who still sustain their lives through simple technologies and small-scale living are “primitive” and unworthy. At best, they should be folded into the modern world. I think they, like all peoples, should retain their self-determination. Survival deserve more support in helping them do this, in the face of unstable but still arrogant modern power.

If you can please help by sponsoring me via my Virgin Money Giving page. Every little helps, and you can donate any time up to a month after the event (the deadline is 30th June).

Thank you!

Developer’s Custom Fields 0.8.2

An unusual release, this. There’s just one new feature, and it’s not one that’s been necessitated by my work or by requests. I won’t do this often, but I recently noticed the Post Meta Inspector plugin, which outputs all the post meta values on post (and page, etc.) edit screens. I realized this is a very simple, but very useful feature. I know that it will save me endless flipping back and forth between WP and phpMyAdmin when I’m trying to track down a custom field issue.

It parses and dumps serialized data. There’s probably other enhancements that are possible, but for now I think it’s useful enough.

Due to the media changes in WP 3.5, as it stands it won’t output on attachment edit screens for previous versions. I don’t think I’ll bother with this—but I probably will find some time in the future to add it to user edit screens, which aren’t currently supported.

There’s no way to turn it off, but if it’s in the way you can fold the meta box up, or hide it with Screen Options.

Planning WordPress image sizes

On larger projects, designs that need to be turned into a custom WordPress theme can have a wide array of image sizes. I’m currently working on such a project, and I thought I’d share a few things that might help others working in a similar situation. My aim is to contribute to a better understanding of how WordPress currently handles image sizing, how understanding this can potentially feed into the design process, and how WordPress developers can respond to design requirements while not making life too confusing for the client’s content editors.

Read more »

Developer’s Custom Fields 0.7.3

For anyone using my Custom Fields plugin, version 0.7.3 is close to being released, with some good improvements:

  • The addition of time and datetime field types, using jQuery Timepicker addon. Thanks to Saurabh Shukla for this contribution!
  • Made the Google Map geocoder bounds update when map bounds change so that only addresses / locations from within the current map display are suggested
  • Moved enqueuing of Google maps JS inside the slt_cf_gmap() function, so the scripts are only used where necessary. This is made possible by registering them to be included in the footer – see
  • NOTE: The datepicker_css_url setting, to account for additional UI elements, is now ui_css_url. Please update this in your code if you use it.

You can download the latest code at GitHub. Especially if you use Google Maps, please test this latest version out and let me know if you find any problems. Hopefully it’ll be released on the WordPress plugins repository soon.

Custom meta tables in WordPress

A large WordPress project I recently worked on had requirements for post and user metadata that resulted in me creating and working with custom database tables. The ins and outs of that particular project are very complex—in the end I’m not sure the custom tables were 100% necessary. However, there are certainly cases where custom metadata tables will be the best approach.

For instance, if you need to get a lot of posts with all their meta values in one go, WP’s data schema may be unworkable. The default wp_postmeta table is structured for maximum flexibility in terms of adding new fields; there isn’t a column for each field, rather the structure allows for fields to be added on an ad hoc basis via the meta_key column. This is great for being flexible about adding new fields, but getting a post or a number of posts together with all metadata will involve a table join for each field. The more joins, the more impact on the query’s performance. The same applies for the similarly-structured wp_usermeta table.

For what it’s worth to anyone attacking this kind of issue, I want to document here how to integrate custom metadata tables with WP’s core metadata handling.

Read more »

Blog archive