问题
I am using a normal host (i.e access to web pages via public_html and no access to php (apache) configuration).
so here what i did
- renamed my web dir => public_html
- renamed app.php (prod application) to index.php
I've also added a route to my page (template) named "littlebird"
Problem
when I call www.mywebsite.com/littlebird => 404 page not found
but when I use www.mywebsite.com/index.php/littlebird every thing works just fine.
回答1:
My original guess was that you didn't have the mod_rewrite turned on.
But during our discussion we've found that you have replaced the original .htaccess with something else.
The original .htaccess could be found by this address: https://github.com/symfony/symfony-standard/blob/master/web/.htaccess
回答2:
It seems to me like you don't have a index.php value within DirectoryIndex.
Try editing your .htaccess file that is located in littlebird and adding/updating it with:
DirectoryIndex index.php index.html
来源:https://stackoverflow.com/questions/20364210/symfony-routing-not-working