[thelist] PHP, functions, include() and precedence

Rich Gray rich at f1central.net
Thu Dec 11 12:28:20 CST 2003


> Let's say I have a PHP script (script.php) which includes two files
> (functions.php and newerfunctions.php).
> 
> If both functions.php and newerfunctions.php have a function called
> foo(), which foo() will I have when I call it in script.php:
> 
> *  The one called first?
> *  The one called last?
> *  Neither, because PHP will throw an error on the second include?

No 3 is the answer - PHP will throw an error..
Rich


More information about the thelist mailing list