function error_handler($msg)
 {
     global $gBitDb;
     bit_error_handler(NULL, NULL, NULL, "FULFILLMENT ERROR: MISSSING PDF for ORDER {$pOrderId} CID " . $prod->mInfo['related_content_id'], $pdfInfo['pdf_file'], '', $prod->mDb);
     print "My Site Error";
     print "Description:";
     printf("%s", $msg);
     exit;
 }
Esempio n. 2
0
function bit_shutdown_handler()
{
    $isError = false;
    $error = error_get_last();
    if ($error && $error['type'] & (E_ERROR | E_PARSE | E_CORE_ERROR | E_COMPILE_ERROR | E_USER_ERROR | E_USER_ERROR)) {
        header("HTTP/1.0 500 Internal Server Error");
        print "Internal Server Error";
        bit_error_handler($error['type'], $error['message'], $error['file'], $error['line']);
    }
}