maiconpinto / cakephp-adminlte-theme

CakePHP AdminLTE Theme
http://maiconpinto.github.io/cakephp-adminlte-theme/
MIT License
174 stars 111 forks source link

Unable to Override the templates #73

Closed phronesis closed 5 years ago

phronesis commented 5 years ago

For some reason, overriding the theme as stated in the documentation is not working: Cake 3.7.4. For example, to override the nav-top, I copied it over to src/Template/Plugin/AdminLTE/Element/nav-top.ctp and modified the file there, but it didn't work.

pereiratiaggo commented 5 years ago

try adding the following lines to the appController

`// src/Controller/AppController.php use Cake\Core\Configure;

public function beforeRender(Event $event) { // Overwrite AppView class $this->viewBuilder()->setClassName('AdminLTE.AdminLTE'); }`

worked here

source: https://github.com/maiconpinto/cakephp-adminlte-theme/wiki/Customize-Layout

maiconpinto commented 5 years ago

Thank you @pereiratiaggo for your answer.

@phronesis let me know if you need more help.