Hi, I'm Jordan Leigh.

A Freelance Javascript Developer from Bristol.

Recently from the lab.

Installing Redis on Amazon EC2 Linux AMI

Amazon EC2, Linux, Redis

Installing Redis on Amazon EC2 Linux AMI

Learn how to instal Redis on Amazon Linux AMI using wget and make.

View Post

Installing MongoDB on Amazon EC2 Linux AMI

Amazon EC2, Linux, MongoDB

Installing MongoDB on Amazon EC2 Linux AMI

Learn how to instal MongoDB on Amazon Linux AMI using yum.

View Post

2D Animated Circle using CSS3 Animation

CSS3, Javascript, Animation

2D Animated Circle using CSS3 Animation

An experiment using a combination of CSS3 and JavaScript to animate a cube based on mouse and touch events. Each individual side of the cube's content is automatically rotated as the user moves the cube to keep the content viewable from any angle.

View Post

include, include_once & require in PHP 5

PHP5

include, include_once & require in PHP 5

There are a number of built in functions that can be used to load external files into PHP scripts. The functions 'include', 'include_once' and 'require' may seem to perform the same function but there are key differences.

View Post

3D Interactive Cube with Rotating Sides using CSS3 and JavaScript

CSS3, Javascript

3D Interactive Cube with Rotating Sides using CSS3 and JavaScript

An experiment using a combination of CSS3 and JavaScript to animate a cube based on mouse and touch events. Each individual side of the cube's content is automatically rotated as the user moves the cube to keep the content viewable from any angle.

View Post

Simple script for creating cross browser input placeholders

HTML5, Javascript, jQuery

Simple script for creating cross browser input placeholders

When building HTML forms, most browsers support the placeholder attribute, but this does not always work in older browsers therefore we have to dynamically add and remove the value of the input attribute using the blur and focus javascript events. Here is a quick solution using JavaScript.

View Post

Interpolating mouse positions using Javascript

Javascript, Node.js, Sockets

Interpolating mouse positions using Javascript

An introduction of how you can use JavaScript for linear interpolation of mouse positions.

View Post

Creating a Router and Dealer messaging system using ZeroMQ, Node.js and PHP

Javascript, Node.js, PHP5, Sockets, ZeroMQ

Creating a Router and Dealer messaging system using ZeroMQ, Node.js and PHP

An example of how you can communicate between Node.js and PHP using ZeroMQ.

View Post

Error handling in Node.js

Javascript, Node.js

Error handling in Node.js

Catching asynchronous and non-asynchronous errors when using Node.js.

View Post

Node.js helper class for node_redis

Javascript, Node.js, Redis

Node.js helper class for node_redis

A JavaScript helper class for interacting with Redis using Node.js.

View Post

__autoload in PHP 5

PHP5

__autoload in PHP 5

Using the autoload magic method to include external PHP files.

View Post

__clone in PHP 5

PHP5

__clone in PHP 5

An example of creating and cloning an object using PHP.

View Post

__call in PHP 5

PHP5

__call in PHP 5

An example of how you can use the __call magic method in PHP.

View Post

__isset & __unset in PHP 5

PHP5

__isset & __unset in PHP 5

Using the magic methods __isset and __unset in PHP.

View Post

__sleep & __wakeup in PHP 5

PHP5

__sleep & __wakeup in PHP 5

When you serialize and unserialize a PHP object, PHP will automatically check to see if there is a __sleep or __wakeup magic method in the class (depending on weather your serializing or unserializing). Here is an example of how you can use both functions.

View Post

__get & __set in PHP 5

__get & __set in PHP 5

Overloading in PHP 5 is a way of dynamically creating properties and methods. To dynamically create properties and methods you have to use magic methods. Here is an example of using __get and __set in PHP.

View Post

Public, Private & Protected in PHP 5

PHP5

Public, Private & Protected in PHP 5

Public, Private and Protected are access identifiers that allow you to specify what level of access other code has to certain variables and methods within an individual class. Here you will find examples of the public, private and protected identifiers.

View Post

__destruct in PHP 5

PHP5

__destruct in PHP 5

is ok, the main difference between protected and private class properties is that protected properties can also be accessed by extended classes.

View Post

__construct in PHP 5

PHP5

__construct in PHP 5

Introduction to the __construct method in PHP5.

View Post

Creating a Class Object with PHP 5

PHP5

Creating a Class Object with PHP 5

In this tutorial I will show you how to create a PHP object using a 'Web Developer' class.

View Post

The Factory Pattern in PHP 5

Patterns, PHP5

The Factory Pattern in PHP 5

The factory is one of the most common OOP patterns. Here I will use the 'shape' concept to demonstrate its use.

View Post