FATAL ERROR OCCURED:

$MySQLError ...

Database Name: $database
Query String: [$query]

Please correct the error then click your 'BACK' button...
Exiting with errorlevel 1... TOBROWSER; exit(1); } function MySQLQueryReport($query, $header, $footer) { /* Description: Function to show results of any MySQL query in a table HTML format. Returns: How many records were retreived via the query Usage: $records=MySQLQueryReport($query, $header, $footer); Arguments: $query is the MySQL query $header is header text to include above the table results $footer is footer text to include below the table results */ global $host, $username, $password, $database; $link=mysql_connect($host,$username,$password) or MySQLError("Unable to connect to MySQL daemon (check host=$host, username or password)"); @mysql_select_db($database) or MySQLError("Unable to open database or database not found"); # Process (get query results, stuff rows into $results, close MySQL) mysql_query($query); $result=mysql_query($query); $records=mysql_numrows($result) or $records=0; print "$header"; if ($records) { // Start the table output print ""; print "
"; print ""; // Print table headers populated with field names for ($i = 0; $i < mysql_num_fields($result); $i++) { print "\n"; } $count=0; for ($count; $count<$records; $count++) { $line = mysql_fetch_array($result, MYSQL_ASSOC); print "\t\n"; foreach ($line as $col_value) { print "\t\t\n"; } // end foreach print "\t\n"; } // end for print "
"; print ""; print mysql_field_name($result, $i); print "
"; print ""; print "$col_value"; print "
\n"; } // end if $records print "
$footer"; return $records; CloseMySQLConnection ($link, $result); } // end of function function CloseMySQLConnection ($link, $result) { /* Description: Free up memory allocated to all results and close current MySQL connection. This function may be used by other functions in this library or externally. Usage: CloseMySQLConnection ($link, $result); Arguments: $link is current open connection $result in current dataset from previous query or empty string */ /* Free resultset */ mysql_free_result($result); /* Closing connection */ mysql_close($link); } function ModifyMySQL($query) { /* Description: Shared function for inserts, updates and deletes only. Returns: Total rows affacted Usage: $rows=DeleteMySQL($query); Arguments: $query is the MySQL query */ global $host, $username, $password, $database; # Input (connect to MySQL and select database) $link=mysql_connect($host,$username,$password) or MySQLError("Unable to connect to MySQL daemon (check host=$host, username or password)"); @mysql_select_db($database) or MySQLError("Unable to open database or database not found"); # Process, return rows, close link # note if -1 returned, that means syntax error in query string mysql_query($query); return mysql_affected_rows(); CloseMySQLConnection ($link, $result); } // end of function OpenMySQL ?>