# Plugin routes not working

**URL:** <https://discourse.cakephp.org/t/plugin-routes-not-working/2691>\
**Category:** Plugins\
**Created:** [June 9, 2017, 3:16pm UTC](https://discourse.cakephp.org/t/plugin-routes-not-working/2691 "2017-06-09T15:16:26Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![j-bone](https://avatars.discourse-cdn.com/v4/letter/j/cc9497/32.png) [@j-bone](https://discourse.cakephp.org/u/j-bone)\
**Post date:** [June 9, 2017, 3:16pm UTC](https://discourse.cakephp.org/t/plugin-routes-not-working/2691/1 "2017-06-09T15:16:26Z")

</div>

As far as I can tell, I’ve configured the routes file on my plugin, and have confirmed it is loading, which indicates the load method is working, with ‘routes’=\>true doing it’s job. I’ve also confirmed the plugin is loaded using Plugin::loaded();

I am getting this:

Error: A route matching “array ( ‘controller’ =\> ‘window-catalogs’, ‘action’ =\> ‘index’, ‘plugin’ =\> ‘window-cleaning’, ‘\_ext’ =\> NULL, )” could not be found.  
(Missing Route Exception);

I can’t figure out why I’m getting this error. Has anyone else cleared this up?

---

<div class="post-metadata">

**Author:** ![rahadur](https://yyz1.discourse-cdn.com/flex029/user_avatar/discourse.cakephp.org/rahadur/32/595_2.png) [@rahadur](https://discourse.cakephp.org/u/rahadur)\
**Post date:** [June 11, 2017, 2:42am UTC](https://discourse.cakephp.org/t/plugin-routes-not-working/2691/2 "2017-06-11T02:42:56Z")

</div>

A controller name should not use dashes when you are defining Routes in Router::scope() or $routes-\>connect() method. The Error is for `'controller' => 'window-catalogs'` it should be `'controller' => 'WindowCatalogs'` if you try this please let me know…

hope this will fix you problem 🙂

Thank you.

---

<div class="post-metadata">

**Author:** ![j-bone](https://avatars.discourse-cdn.com/v4/letter/j/cc9497/32.png) [@j-bone](https://discourse.cakephp.org/u/j-bone)\
**Post date:** [June 11, 2017, 3:58am UTC](https://discourse.cakephp.org/t/plugin-routes-not-working/2691/3 "2017-06-11T03:58:54Z")

</div>

Thanks, dude. My route syntax was incorrect. The plugin was baked, which wrote some code that didnt work. I studied up the routing section in the Cook Book and realized I hadn’t defined a $route-\>connect properly.

---

<div class="post-metadata">

**Author:** ![Din0saur](https://yyz1.discourse-cdn.com/flex029/user_avatar/discourse.cakephp.org/din0saur/32/323_2.png) [@Din0saur](https://discourse.cakephp.org/u/Din0saur)\
**Post date:** [July 19, 2017, 7:39pm UTC](https://discourse.cakephp.org/t/plugin-routes-not-working/2691/4 "2017-07-19T19:39:52Z")

</div>

Would not hurt if you put the soluction you find out.

I’m stucked with similar problem and you could had help!

☹
