index.php 2.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465
  1. <?php
  2. /**
  3. * Laravel - A PHP Framework For Web Artisans
  4. *
  5. * @package Laravel
  6. * @author Taylor Otwell <taylor@laravel.com>
  7. */
  8. header('Access-Control-Allow-Origin: https://rcmap.jucai.gov.cn');
  9. header("Access-Control-Allow-Methods:GET, POST, OPTIONS, DELETE");
  10. header("Access-Control-Allow-Headers:*");
  11. header('Strict-Transport-Security:max-age=180');
  12. header('X-Download-Options: noopen');
  13. header('X-Permitted-Cross-Domain-Policies: none');
  14. define('LARAVEL_START', microtime(true));
  15. /*
  16. |--------------------------------------------------------------------------
  17. | Register The Auto Loader
  18. |--------------------------------------------------------------------------
  19. |
  20. | Composer provides a convenient, automatically generated class loader for
  21. | our application. We just need to utilize it! We'll simply require it
  22. | into the script here so that we don't have to worry about manual
  23. | loading any of our classes later on. It feels great to relax.
  24. |
  25. */
  26. require __DIR__.'/../vendor/autoload.php';
  27. /*
  28. |--------------------------------------------------------------------------
  29. | Turn On The Lights
  30. |--------------------------------------------------------------------------
  31. |
  32. | We need to illuminate PHP development, so let us turn on the lights.
  33. | This bootstraps the framework and gets it ready for use, then it
  34. | will load up this application so that we can run it and send
  35. | the responses back to the browser and delight our users.
  36. |
  37. */
  38. $app = require_once __DIR__.'/../bootstrap/app.php';
  39. /*
  40. |--------------------------------------------------------------------------
  41. | Run The Application
  42. |--------------------------------------------------------------------------
  43. |
  44. | Once we have the application, we can handle the incoming request
  45. | through the kernel, and send the associated response back to
  46. | the client's browser allowing them to enjoy the creative
  47. | and wonderful application we have prepared for them.
  48. |
  49. */
  50. $kernel = $app->make(Illuminate\Contracts\Http\Kernel::class);
  51. $response = $kernel->handle(
  52. $request = Illuminate\Http\Request::capture()
  53. );
  54. $response->send();
  55. $kernel->terminate($request, $response);