Class Firebase\JWT\JWT not found

前端 未结 5 1316
旧时难觅i
旧时难觅i 2020-12-20 14:57

I want to use pure firebase/php-jwt library in my code. Firstly, I go to /var/www/html/ and like the official library page is suggesting, I do this



        
5条回答
  •  离开以前
    2020-12-20 15:12

    I added only one line to your code to get my code to work:

    require __DIR__ . '\vendor\autoload.php';
    use Firebase\JWT\JWT;
    
    /* the rest of your code after this */
    

    I did not have to modify the jwt.php file at all.

提交回复
热议问题