JSON encoder/decoder compatible with PHP 5.1 and above.