Debuggin PHP parsing function