xdebug, is something all vim users should know about if they are developing with php. for all the years i used to debug with the simple 'echo' statement, mostly because i knew the code and it wasn't so complex.
If you follow the 'interactive directions' on xdebug you will find a nice
tutorial
I am not sure how i debugged php code without it.