0
我設立一個新的Symfony2項目 我的routing.yml找不到我的控制器Symfony2的路由找不到控制器
我控制器位於:
在我的應用程序/配置src/Bank/SNSBundle/Controller/HomeController.php
/使用routing.yml:
home:
path: /blah
defaults: { _controler: BankSNSBundle:Home:Index}
,這是我家的控制器:
<?php
namespace Bank\SNSBundle\Controller;
use Symfony\Bundle\FrameworkBundle\Controller\Controller;
class HomeController extends Controller {
/**
* @return \Symfony\Component\HttpFoundation\Response
*/
public function IndexAction(){
return $this->render('BankSNSBundle:Home:index.html.twig', array('name' => "Ralph"));
}
}
當我去/等等我得到這個錯誤:
Unable to find the controller for path "/blah". The route is wrongly configured.
可以annyone Telle公司我有什麼錯我的代碼?
拉爾夫
糟糕,是的錯字,非常感謝 –