PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!
On a similar thread is it possible for PHP to detect which page or URL is calling it?
I am trying to work out how to make a PHP file check where it is being included() from.. and then do something depending on the result.
If it's being included() from a page on my server then it will do on thing.. if it's being included() or run from anywhere else then it will do another.