why does using set_error_handler() squelch my errors?
<p>I am handling errors with the following script:</p>

<pre><code>&lt;?php # config.inc.php

// This script establishes email default settings.
// This script determines how errors are handled.

// Email Settings
$site['from_name'] = 'x'; // from email name
$site['from_email'] = 'x@x.com'; // from email address

// Just in case we need to relay to a different server, 
// provide an option to use external mail server.
$site['smtp_mode'] = 'enabled'; // enabled or disabled
$site['smtp_host'] = 'mail.x.com';
$site['smtp_port'] = null;
$site['smtp_username'] = 'admin@x.com'; 
$site['smtp_password'] = 'x';

// Error handling:
// Flag variable for site status:
$live = TRUE;

ini_set('display_errors','On');
error_reporting(E_ALL);

// Error log email address:
$admin_email = 'x@x.com';

date_default_timezone_set('America/New_York');

// Create the error handler.
function my_error_handler ($e_number, $e_message, $e_file, $e_line, $e_vars) {

    global $live, $admin_email;

    // Build the error message.
    $message = "An error occurred in script '$e_file' on line $e_line: \n&lt;br /&gt;$e_message\n&lt;br /&gt;";

    // Add the date and time.
    $message .= "Date/Time: " . date('n-j-Y H:i:s') . "\n&lt;br /&gt;";

    // Append $e_vars to the $message.
    $message .= "&lt;pre&gt;" . print_r ($e_vars, 1) . "&lt;/pre&gt;\n&lt;br /&gt;";

    if ($live) { // Don't show the specific error.

        error_log ($message, 1, $admin_email); // Send email.

        // Only print an error message if the error isn't a notice.
        if ($e_number != E_NOTICE) {
            echo '&lt;div id="Error"&gt;A system error occurred. An administrator has been notified. We apologize for the inconvenience.&lt;/div&gt;&lt;br /&gt;';
        }

    } else { // Development (print the error).
        echo '&lt;div id="Error"&gt;' . $message . '&lt;/div&gt;&lt;br /&gt;';
    }

} // End of my_error_handler() definition.

// Use my error handler.
set_error_handler ('my_error_handler');

?&gt;
</code></pre>

<p>If I include this script in a script with an error, the error does not get displayed. If I comment out the call to set_error_handler(), the error does get displayed. What am I doing wrong that could be causing this behavior?</p>
