2016-05-14 147 views

回答

1

你有两个选择

电话拨打方法的哈希门面 Hash::make('string_here')

或者使用全局助手功能bcrypt('string_here')

例子:

//Hash facade example 
$simpan['password']= Hash::make(Request::input('password')); 

//bcrypt global helper function 
$simpan['password']= bcrypt(Request::input('password')); 

资源:

https://laravel.com/docs/5.1/hashing

+0

谢谢,它工作 –