Wrote my first WordPress plugin today (for www.bookthing.co.uk), it’s a pretty simple plugin architecture especially if you’re not trying to do anything too clever. I just wanted a shortcode (some text you put into a post which is expanded by a plugin) to read some values from some custom fields and include them in the article footer. It saves having to paste lots of formatting HTML into each post and lets you just suck content from the custom fields.
I was surprised I couldn’t find a simple ‘template’ style plugin on the WordPress site, maybe I was just using the wrong search terms. It’s the kind of thing that would be very useful for building common information boxes for reviews, etc. Anyway, I hacked together a 59 line php file, of which around 1/3rd is info and license to read two custom fields and whack them into a div.
Took about 9000% less time than I expected.
Related posts:
- A month with WordPress It’s just over a month since I left Blogger and...
- WordPress search sucks I really like WordPress, I’m glad I moved to it...
- Stats, stats and more stats (and lies!) I’m a bit of a web-stat-aholic. Despite the fact that...
- WordPress I’m quite liking WordPress I have to say. I’ve still...
- Postmove reflection It’s nineteen days since I moved away from Blogspot and...
Recent Comments