Bravo-kernel/application-examples


#1

I have tried using this tutorial for creating jwt token. But many functions of friendofcrud plugin doesn’t work for me. I am using PHP 7.2 in the local server which says many of the functions are deprecated.

http://www.bravo-kernel.com/2015/04/how-to-add-jwt-authentication-to-a-cakephp-3-rest-api/

Can anyone help how to use CakePHP crud instead of the plugin.


#2

whats your cakephp version? You need fix the deprecated functions with migration guide:
https://book.cakephp.org/3.0/en/appendices/3-x-migration-guide.html

example:

$this->loadComponent('Auth', [
            'storage' => 'Memory',
            'authenticate' => [
                'Form' => [
                    'scope' => ['Users.active' => 1] //this is deprecated
                ],

#3

I am using Cakephp version 3.6