kieranbarnes Independent PHP, WordPress & CubeCart Programmer

Protect wp-admin with Nginx

Posted on May 1, 2012

Posted by kieran

Are you running WordPress on nginx? A massive security win is securing your wp-admin area by limiting IP access. How? Easy.

Drop these lines into your nginx.conf or relevant vhost config file

Adding .html suffix to WordPress Rewrites

Posted on March 22, 2012

Posted by kieran

Here's a quick way to give your WordPress install a static look.

Add this code to your functions.php

[Snippet] Adding your custom taxonomy to post/page list in WordPress

Posted on March 5, 2012

Posted by kieran

Custom Taxonomies are amazing for organising your post data. Here's a simple way of showing your custom taxonomies on the post/page list in wp-admin.

In the image below you can see we are now showing the custom taxo Brand in the post list.

 

Here's how I did it

Automatic Photo Blogging with WordPress

Posted on March 5, 2012

Posted by kieran

My latest WordPress challenge was to automate a photo blog site. The photo blog post content would just consist of a title and a featured image. No content. As per normal photo blog style sites.

This solution takes an image at random from a folder and posts it in WordPress. It relies on a healthy collection of images to work from.

Really simply, it needed to select a photo at random and post it. Sounds easy, until to you start to code it.

Here's my solution.

Removing all comment functionality in WordPress

Posted on February 27, 2012

Posted by kieran

As more and more people adopt WordPress as a CMS, more and more of the original blog functionality is becoming redundant. Comments are one of.

Here is how to conclusively remove all comment functions in WordPress

WordPress Opengraph and Microdata Generation without a plugin

Posted on February 17, 2012

Posted by kieran

Its really useful to have Opengraph (Facebook) and Microdata (Twitter) information in your blog header.

The Facebook Opengraph and Schema.org microdata lets you optimize your blog much more better and helps search engines to index your website better to show rich snippet.

It also lets Facebook and Twitter users to share your blog with proper title, description, url and image.

There are loads of plugins available to do this, but why use a plugin when its only a few lines of code?

[Snippet] Matching hash tags in Twitter content

Posted on February 17, 2012

Posted by kieran

Here's a super simple way of matching hash tag content in a tweet.
Perhaps you want to store hash tags as WordPress tags? Or simply transform how they are displayed?

  1. preg_match_all('/#(\w+)/',$data->text,$hashtag_matches);
  2. print_r($hashtag_matches);

Where $data->text is your tweet string.

Easy.

Tagged as: No Comments

Tipping Point (Arts Council)

Posted on February 16, 2012

Posted by kieran

Date: February 2012 - Current http://www.tippingpoint.org.uk/Team: Developer (Myself), Project manager

  • Full theme WordPress theme build
  • Custom WordPress events management system
Tagged as: No Comments

Strictly Auto Tags Plugin & Custom Posts

Posted on February 6, 2012

Posted by kieran

The Strictly Auto Tags plugin for WordPress does a fantastic job at automatically tagging content so your authors don't have to. Most of the time it creates useful and usable tags with no intervention.

It's only downfall is it doesn't work with Custom Post Types.

No problems, its an easy fix hack.

Neil Anthony Kitchens

Posted on January 26, 2012

Posted by kieran

Neil Anthony approached me in May of 2010, their brief was simple, create a site that reflected the class and high quality kitchens they designed and installed, make the site clear, crisp, informative, easy to navigate and most importnatly easy to update by the client. Iachieved all of these goals and the staff at NA who weren't particulalry PC literate regularly updat etheir site to reflect new product and special offers.

Page 1 of 41234