Code Snippets

Showing 21 to 30 of 34 posts.


Posted on August 4th, 2014 by Graeme

RSS namespaces

Here we use a sample bit of RSS that contains two thumbnails, which belong to a namespace.

Read more...


Posted on July 17th, 2014 in PHP, WordPress by Graeme

WordPress infinite scroll

How to implement infinite scroll in WordPress by setting a post offset value for pagination

Read more...


Posted on April 30th, 2014 in JavaScript by Graeme

jQuery binding tip

This is a good little trick I’ve just picked up, which allows you to bind multiple functions to the same event (e.g. click), without each of the functions effecting the other.

Read more...


Posted on March 14th, 2014 in PHP

PHP Explode

How to use PHP exlode

Read more...


Posted on March 4th, 2014 in WordPress by Graeme

Creating a WordPress shortcode

Shortcode demo of a function returning the URL of the WordPress site.

Read more...


Posted on February 19th, 2014 in WordPress by Graeme

Woocommerce 2.0 plugin hooks

How to upgrade an old WooCommerce plugin to be compliant with WooCommerce 2.0

Read more...


Posted on February 4th, 2014

SCP Command - local to remote

To copy a folder from a local machine to a remote server, you can use the SCP command.

Read more...


Posted on February 2nd, 2014

CSS checkbox alignment

Using vertical-align to align checkboxes

Read more...


Posted on January 6th, 2014 in PHP

PHP timestamping and fwrite

Storing timestamps in a database with PHP

Read more...


Posted on November 19th, 2013 by Graeme

Abstract class order

The abstract class must be included before the extending class, and the extending class cannot be instantiated until before its definition.

Read more...