尝试在Symfony 2.1中打开路由时出现此错误
我真的不知道在哪里检查.互联网上什么都没有.
非常感谢您的帮助:
CRITICAL – Uncaught PHP Exception Twig_Error_Runtime: “An exception has been thrown during the rendering of a template (“Unable to generate a URL for the named route “_wdt” as such route does not exist.”) in “@WebProfiler/Profiler/toolbar_js.html.twig” at line 15.” at /home/milos/workspace/merrin3.0/vendor/twig/twig/lib/Twig/Template.PHP line 280
如果启用了探查器但缺少路由配置,则会在dev环境中抛出此异常.
原文链接:https://www.f2er.com/php/135561.htmlUnable to generate a URL for the named route "_wdt" as such route does not exist.
请检查您的app / config / routing_dev.yml是否包含以下行:
# app/config/routing_dev.yml _wdt: resource: "@WebProfilerBundle/Resources/config/routing/wdt.xml" prefix: /_wdt _profiler: resource: "@WebProfilerBundle/Resources/config/routing/profiler.xml" prefix: /_profiler
这将解决您的问题.