Skip to content

Instantly share code, notes, and snippets.

@leonardosapiras
Created June 9, 2011 22:57
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save leonardosapiras/1017964 to your computer and use it in GitHub Desktop.
Save leonardosapiras/1017964 to your computer and use it in GitHub Desktop.
//file a.php
function print_something() {
$x = function_where_this_function_was_called;
$y = file_where_this_function_was_called;
echo $x; //do_something
echo $y; //b.php
}
//file b.php
function do_something() {
print_something();
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment