1. Go to this page and download the library: Download yzh52521/think-hashing library. Choose the download type require.
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
declare(strict_types=1);
namespace app\controller;
use yzh52521\Hashing\Hash;
class UpdatePasswordController
{
public function update(Request $request)
{
$user['password'] = Hash::make($request->input('new_password'));
$user->save();
}
}