Reputation: 8769
When open page I get error:
Plugin Authority could not be found.
Error: An Internal Error Has Occurred.
I created new plugin under app/Plugin
with this structure:
Green color represents newly created files.
I created this plugin the same way all other plugins are made (white directories). My route to page is:
Router::connect('/authority', array('plugin'=>'Authority', 'controller' => 'Authority', 'action' => 'index'));
My routes.php
include this line:
CakePlugin::routes();
This is example of some other route that is working:
Router::connect('/login', array('plugin' => 'users','controller' => 'users', 'action' => 'login'));
Here are some other files from the plugin:
AuthorityAppController.php
<?php
class AuthorityAppController extends AppController {
}
AuthorityController.php
<?php
class AuthorityController extends AuthorityAppController {
public function index(){
}
}
AuthorityAppModel.php
<?php
class AuthorityAppModel extends AppModel {
}
And this is my bootstrap line of code for activating plugins:
bootstrap.php
CakePlugin::loadAll(array( 'routes' => true ));
Upvotes: 0
Views: 759
Reputation: 8769
The issue was with the cache. I cleared tmp
directory and it works now.
cd app/tmp
rm -rf *
Upvotes: 1