开发者

CakePHP - Using User model in SecurityComponent

开发者 https://www.devze.com 2023-01-09 00:18 出处:网络
开发者_如何学运维I\'m creating a application based on REST requests and I\'m using SecurityComponent for HTTP Authorisation. My question is - how can I use a User model with it? Instead of giving a ar
开发者_如何学运维

I'm creating a application based on REST requests and I'm using SecurityComponent for HTTP Authorisation. My question is - how can I use a User model with it? Instead of giving a array of usernames and passowrds...

Cheers, Lucas


  1. Try to copy file app_controller.php to /app folder
  2. Try to add the line

    var $uses = array('User');

after

class AppController extends Controller

line

0

精彩评论

暂无评论...
验证码 换一张
取 消