http://localhost/Symfony/web/app.php/demo/hello/Alex
节目
“无法从“D:/UserData/WWWRoot/Symfony/app/config/routing.yml”导入资源“@AcmeDemoBundle/Controller/SecuredController.php”。确保“AcmeDemoBundle/Controller/SecuredController.php”包已正确注册并加载到应用程序内核类中。”
这是我的路线app\config\routing.yml
处理 ESI 的内部路由配置
_internal:
resource: "@FrameworkBundle/Resources/config/routing/internal.xml"
prefix: /_internal
_welcome:
pattern: /
defaults: { _controller: AcmeDemoBundle:Welcome:index }
_demo_secured:
resource: "@AcmeDemoBundle/Controller/SecuredController.php"
type: annotation
_demo:
resource: "@AcmeDemoBundle/Controller/DemoController.php"
type: annotation
prefix: /demo