By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
438,278 Members | 1,357 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 438,278 IT Pros & Developers. It's quick & easy.

Call to undefined function displayHeader()

P: 1
Can any body help with the above error and how to fix it . here is the code refered to in the error

Fatal error: Call to undefined function displayHeader() in C:\wamp\www\functions.php on line 15

require( "config.php" );
function dbConnect()
global $dbHost, $dbUser, $dbPasswd, $dbName, $dbConn, $numComments, $table;
$dbConn = @mysql_connect( $dbHost, $dbUser, $dbPasswd ) or error( mysql_error() );
mysql_select_db($dbName, $dbConn) or die("Error 2 in Application: " . mysql_error());

function error( $error )
global $forumTitle;
displayHeader( "Error Page" );
echo "
<center><h4>&lt;Error Page&gt;</h4></center>
<center><h4><font color=#FF0000>Error: $error</font></h4></center>
<DIV align=center><a href=javascript:history.back();>Back</a>&nbsp; |&nbsp; <a href=forum.php>$forumTitle</a></DIV>";
Apr 29 '07 #1
Share this Question
Share on Google+
1 Reply

Expert 100+
P: 801
Your script is unable to find where is this functions has been defined. displayHeader() is a user defined function, include the file in the script where you have defined this.
Apr 30 '07 #2

Post your reply

Sign in to post your reply or Sign up for a free account.