adding php mode and correcting path for OSX
removing temp files