diff --git a/.htaccess b/.htaccess index 618291d..4ec0df7 100644 --- a/.htaccess +++ b/.htaccess @@ -1,2 +1,4 @@ -RewriteEngine On -RewriteRule ^$ /public [L] +RewriteEngine on +RewriteCond %{REQUEST_FILENAME} !-f +RewriteCond %{REQUEST_FILENAME} !-d +RewriteRule ^(.*)$ index.php/$1 [NC,L,QSA] diff --git a/public/assets/css/main.css b/assets/css/main.css similarity index 100% rename from public/assets/css/main.css rename to assets/css/main.css diff --git a/public/assets/logo.png b/assets/logo.png similarity index 100% rename from public/assets/logo.png rename to assets/logo.png diff --git a/composer.json b/composer.json index 7f151af..41d7dd7 100644 --- a/composer.json +++ b/composer.json @@ -10,7 +10,7 @@ }, "scripts": { "run": "composer install && composer start", - "start": "php -S 0.0.0.0:8080 -t public public/index.php" + "start": "php -S 0.0.0.0:8080" }, "autoload": { "psr-4": {"Inforbank\\": "src/"} diff --git a/public/index.php b/index.php similarity index 91% rename from public/index.php rename to index.php index 4b0a035..7669d00 100644 --- a/public/index.php +++ b/index.php @@ -38,10 +38,10 @@ if (PHP_SAPI == 'cli-server') { /** * Require the Composer autoloader to load dependencies */ -require __DIR__ . '/../vendor/autoload.php'; +require __DIR__ . '/vendor/autoload.php'; /** * Load the bootstrapping script */ -include __DIR__ . '/../src/bootstrap.php'; +include __DIR__ . '/src/bootstrap.php'; diff --git a/public/.htaccess b/public/.htaccess deleted file mode 100644 index 4ec0df7..0000000 --- a/public/.htaccess +++ /dev/null @@ -1,4 +0,0 @@ -RewriteEngine on -RewriteCond %{REQUEST_FILENAME} !-f -RewriteCond %{REQUEST_FILENAME} !-d -RewriteRule ^(.*)$ index.php/$1 [NC,L,QSA]