Esempio n. 1
0
    public function init()
    {
        if ($this->debug) {
            ini_set('display_errors', 1);
            error_reporting(-1);

            DebugUniversalClassLoader::enable();
            ErrorHandler::register();
            ExceptionHandler::register();
        } else {
            ini_set('display_errors', 0);
        }
    }
Esempio n. 2
0
 public function init()
 {
     if ($this->debug) {
         ini_set('display_errors', 1);
         error_reporting(-1);
         DebugClassLoader::enable();
         ErrorHandler::register($this->errorReportingLevel);
         if ('cli' !== php_sapi_name()) {
             ExceptionHandler::register();
         }
     } else {
         ini_set('display_errors', 0);
     }
 }
Esempio n. 3
0
<?php

use Symfony\Component\HttpKernel\Debug\ErrorHandler;
use Symfony\Component\HttpKernel\Debug\ExceptionHandler;
require_once __DIR__ . '/../vendor/autoload.php';
error_reporting(-1);
ErrorHandler::register();
if ('cli' !== php_sapi_name()) {
    ExceptionHandler::register();
}
$app = (require __DIR__ . '/../src/bootstrap.php');
require __DIR__ . '/../src/controllers.php';
$app['debug'] = true;
$app->run();
 public function init()
 {
     ini_set('display_errors', 0);
     if ($this->debug) {
         error_reporting(-1);
         if (class_exists('Symfony\\Component\\ClassLoader\\DebugClassLoader')) {
             DebugClassLoader::enable();
         }
         ErrorHandler::register($this->errorReportingLevel);
         if ('cli' !== php_sapi_name()) {
             ExceptionHandler::register();
         } else {
             ini_set('display_errors', 1);
         }
     }
 }