Possible Duplicate:
How to find out where a function is defined?
I have a fairly complex OOP PHP project with lots of classes, libraries and helpers to work with.
While debugging, I sometimes find it hard to locate which instance of a specific function is used in when it exists in different files or classes and I can't tell which class or library was included without looking through the entire code to this point.
I was wondering if there is a language construct, a function or even an external tool (e.g. a debugger) that can help me locate exactly in which file and on which line is a specific function located.
E.g. something like:
moditem(25); // How I call the function usually
echo locate_function('moditem');
To display something like:
Function moditem() is located in file: lib/users.php, line 234.
Here's a snippet:
...
return TRUE;
}
function moditem($id){
$modify = $this->modify($id);
return $modify;
}
...
My IDE has a way to lead me to the function declaration, but it gets confused when I have 20 files that have a different version of the function with the same name.