-
Notifications
You must be signed in to change notification settings - Fork 4
/
server.php
42 lines (39 loc) · 1.44 KB
/
server.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
<?php
/**
* Gamify - Gamification platform to implement any serious game mechanic.
*
* Copyright (c) 2018 by Paco Orozco <paco@pacoorozco.info>
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* Some rights reserved. See LICENSE and AUTHORS files.
*
* @author Paco Orozco <paco@pacoorozco.info>
* @copyright 2018 Paco Orozco
* @license GPL-3.0 <http://spdx.org/licenses/GPL-3.0>
*
* @link https://github.com/pacoorozco/gamify-laravel
*/
/**
* Laravel - A PHP Framework For Web Artisans
*
* @author Taylor Otwell <taylor@laravel.com>
*/
$uri = urldecode(
parse_url($_SERVER['REQUEST_URI'], PHP_URL_PATH)
);
// This file allows us to emulate Apache's "mod_rewrite" functionality from the
// built-in PHP web server. This provides a convenient way to test a Laravel
// application without having installed a "real" web server software here.
if ($uri !== '/' && file_exists(__DIR__.'/public'.$uri)) {
return false;
}
require_once __DIR__.'/public/index.php';