codeignitor sample from https://github.com/ericterpstra/ci_sock