Adding the php shim. It has the best tests

and examples.