CakePHP 2.x User Management Premium Plugin Version 2.2.x
Must Know Necessary Things
You must follow the necessary things for better use of this plugin-
- App Controller (yourapp/app/Controller/AppController.php) Download App Controller
- This controller must use 'Form', 'Html', 'Session', 'Js', 'Usermgmt.UserAuth', 'Usermgmt.Image' helpers.
- This controller must use 'Session','RequestHandler', 'Usermgmt.UserAuth' components.
- This controller must have 'userAuth' private function.
- This controller must have 'beforeFilter' function and should call 'userAuth' from inside it.
- Plugin already has Security feature. If you want use security on rest of the pages of site you should use 'Security' component in this controller.
- Bootstrap (yourapp/app/Config/bootstrap.php)
- This file is used for loading plugins.
- Please load User Management Plugin in this file
CakePlugin::loadAll(array('Usermgmt' => array('routes' => true, 'bootstrap' => true)));
- Please note in above syntax 'routes' => true, 'bootstrap' => true must present.
- beforeFilter (a function in any controller)
- If you use this function in your controller you must have parent::beforeFilter(); as a first line in this function.
- If you do not use parent::beforeFilter(); in this function this can break authentication functionality of your site.
- Basically authentication is controlled from beforeFilter function of App Controller. If you use beforeFilter function in other controller this means you are overriding this function, In this case App Controller beforeFilter function will not execute. For avoiding this you should use parent::beforeFilter(); in any override beforeFilter function.
- Your layout must include plugin CSS and JS file and other things Download Default Layout
- You must include plugin css, js and other setting in your default layout (yourapp/app/View/Layouts/default.ctp)
- For more information reffer README file
- Image Folder
- By default profile photos folder name is umphotos (yourapp/app/webroot/img/umphotos)
- This folder must have write permissions for e.g. 777 permissions
- Also img folder (yourapp/app/webroot/img) should have write permissions for e.g. 777 permissions
- Google and Yahoo Authentication
- If google and yahoo authentication are not working on your website please contact me at chetanvarshney@gmail.com
- Twitter Bootstrap
- If you are using 2.2 version then you should download Twitter Bootstrap package from Twitter Bootstrap Official Website
- copy all css files for e.g. bootstrap.css, bootstrap.min.css, bootstrap-responsive.css, bootstrap-responsive.min.css and paste them in to yourapp/app/webroot/css directory
- copy all js files for e.g. bootstrap.js, bootstrap.min.js and paste them in to yourapp/app/webroot/js directory
- copy all images and paste them in to yourapp/app/webroot/img directory
- Tinymce and Ckeditor code
- Download Tinymce editor from Tinymce Official Website
- Extract it somewhere now go tinymce/jscripts directory and copy tiny_mce folder and go to yourapp/app/webroot/js directory and paste here.
- Download Ckeditor editor full package from Ckeditor Official Website
- Make sure you have downloaded full package
Extract it somewhere now go copy ckeditor folder and go to yourapp/app/webroot/js directory and paste here.