I have installed a fresh installation of laravel and everything is working fine except that if I go to the url without entering the index.php at the end, then it doesn't work.
I am using:
http://localhost/index.php
And in this case, the page appears correctly but if I enter only:
http://localhost/
Then it is not working as expected.
How to see if it works or not, I have installed the debugbar and in the first case it is showing but in second case it is not.
I have update the apache2 config so that it starts in the public directory and also I made sure that it accepts php with DirectoryIndex index.php in the 000-default.conf.
Should I set up something so that it forces a redirect to index.php when hitting the directory in the browser?
Here is what I get from my phpinfo for the loaded modules in apache2 handler, I can see the mod_rewrite
Loaded Modules
core mod_so mod_watchdog http_core mod_log_config mod_logio mod_version mod_unixd mod_access_compat mod_alias mod_auth_basic mod_authn_core mod_authn_file mod_authz_core mod_authz_host mod_authz_user mod_autoindex mod_deflate mod_dir mod_env mod_filter mod_mime prefork mod_negotiation mod_php7 mod_reqtimeout mod_rewrite mod_setenvif mod_status
please change the contents of httpd.conf file like as below.
<IfModule dir_module>
DirectoryIndex index.php index.pl index.cgi index.asp index.shtml index.html index.htm \
default.php default.pl default.cgi default.asp default.shtml default.html default.htm \
home.php home.pl home.cgi home.asp home.shtml home.html home.htm
</IfModule>
...
Listen 8094
<VirtualHost *:8094>
DocumentRoot "D:\yoursouce\public"
<Directory "D:\yoursouce\public">
Require all granted
AllowOverride All
Order allow,deny
Allow from all
</Directory>
</VirtualHost>
...
Then try
http://localhost:8094/
Best Regards