For a customer of mine I'm building a website. For this I use the Laravel framework. Now I know the best practice is to set the public directory as DocumentRoot, but the problem is, I can't. So I've done some research, and I saw that you could use .htaccess to handle this little problem. The snippet that's on the laravel forums is the following:
<IfModule mod_rewrite.c>
RewriteEngine on
RewriteCond %{REQUEST_URI} !^public
RewriteRule ^(.*)$ public/$1 [L]
</IfModule>
But when I try this, I get a 500 Internal Server error.
I found that the problem was the (.*)
part of the fourth line... But I just can't see what's wrong with it.
So does anybody know what's wrong with this snippet, why am I getting a 500 error...