Tuesday, April 7, 2015

CakePHP 3: How to Bake template from vendor/authorname/pluginname?

If you want to create a package / plugin in vendor folder, which will be used for development eg Admin plugin, how do you set up the structure of the folders and where you will put the template files?

I try the following:

myapp/    vendor/      salines/        admintheme/          src/            Template/              Bake/               Layout/               Template/               ... etc

I added in the vendor/cakephp-plugins.php

'AdminTheme' => $baseDir . '/vendor/salines/admintheme/'

When I type in the console:

cake bake template Admin.users -t AdminTheme

I get an error message: AdminTheme is not valid value for --theme

in the console are shown, possible options Bake, Migrations, therefore this my plugin is not shown.

Please help, what do I need to do, in order to have a functional plugin, after which I want to share with you.

thank You

http://stackoverflow.com/questions/29502877/cakephp-3-how-to-bake-template-from-vendor-authorname-pluginname

--
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

---
You received this message because you are subscribed to the Google Groups "CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email to cake-php+unsubscribe@googlegroups.com.
To post to this group, send email to cake-php@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.

No comments: