标签:加载 handle 源码解析 使用 load cts ati end bug
<?php
/*设置脚本开始时间 define(‘LARAVEL_START‘, microtime(true));
引入composer的自动加载,在composer.json中可以看出相当于
require(‘app/*‘) require(‘database/*‘) require(‘vendor/*‘)
之后使用时只要引入命名空间即可
*/
require __DIR__.‘/../bootstrap/autoload.php‘;
$app = require_once __DIR__.‘/../bootstrap/app.php‘; /*在phpstrom中ctrl+左键单击查看app.php代码。*/
/*app.php代码如下:*/
/*首先创建app服务容器,即ioc容器*/
$app = new Illuminate\Foundation\Application( realpath(__DIR__.‘/../‘) ); $app->singleton( Illuminate\Contracts\Http\Kernel::class, App\Http\Kernel::class ); $app->singleton( Illuminate\Contracts\Console\Kernel::class, App\Console\Kernel::class ); $app->singleton( Illuminate\Contracts\Debug\ExceptionHandler::class, App\Exceptions\Handler::class ); return $app;
标签:加载 handle 源码解析 使用 load cts ati end bug
原文地址:http://www.cnblogs.com/sair/p/6820483.html