app.php 749B

12345678910111213141516171819202122232425
  1. <?php
  2. use Symfony\Component\ClassLoader\ApcClassLoader;
  3. use Symfony\Component\HttpFoundation\Request;
  4. $loader = require_once __DIR__.'/../app/bootstrap.php.cache';
  5. // Use APC for autoloading to improve performance.
  6. // Change 'sf2' to a unique prefix in order to prevent cache key conflicts
  7. // with other applications also using APC.
  8. /*
  9. $loader = new ApcClassLoader('sf2', $loader);
  10. $loader->register(true);
  11. */
  12. require_once __DIR__.'/../app/AppKernel.php';
  13. //require_once __DIR__.'/../app/AppCache.php';
  14. $kernel = new AppKernel('prod', false);
  15. $kernel->loadClassCache();
  16. //$kernel = new AppCache($kernel);
  17. $request = Request::createFromGlobals();
  18. $response = $kernel->handle($request);
  19. $response->send();
  20. $kernel->terminate($request, $response);