Fun with Functions..

From: Date: Thu, 19 Apr 2001 14:23:19 +0000
Subject: Fun with Functions..
Groups: php.qa 
Request: Send a blank email to php-qa+get-2829@lists.php.net to get a copy of this message
Here is the deal.. I'm trying to include a site specific show_header() function.. The database query includes a file depending on the result. So, if they want to redefine it, in their include file they put: function show_header() { // generic header stuffs... } and in the global include file, >I< put this: function main_show_header() { ?> HEADER!!! <br> <? } if (!function_exists("show_header")) { echo "create me a function?"; function show_header() { echo "callin my superior..."; main_show_header(); } } Now for some reason... the function show_header() isn't getting called, or isn't calling main_show_header()... I see "create me a function" but i don't see "callin my superior.." or "HEADER!!!" HELP!! (please respond with e-mail.. i don't wanna have to look through the newsgroup :P)

« previous php.qa (#2829) next »