开发者

Problems with symfony homepage in routing.yml

I'm following the Jobeet tutorial on symfony 1.4 website and i'm having some problems in routing.yml.

http://www.symfony-project.org/jobeet/1_4/Doctrine/en/04

I already created the jobeet module and specified it in my routing.yml. When i go to the frontend_dev, it works perfectly. However, when going through index.php, it shows the default symfony homepag开发者_Go百科e. As if i hadn't changed the routing.

Are there different routing for development and production? What can be causing this? Thanks in advance.


Have you cleaned your cache? Changes in routing.yml will only take effect on production after clearing the cache.

php symfony cache:clear

The reason it worked when you used frontend_dev.php is that this loads the application using the dev environment. In dev mode, Symfony checks to see if configuration files were modified since the last request and will override the cached versions if they have changed.


This sounds like a mod_rewrite issue.

What you will need to do, is ensure that your apache instance has mod_rewrite enabled.

Typically, what you would do is put the .htaccess file that is found in your /symfonyproject/web folder, and copy it into your web root folder.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜