A set of useful functions for PHP