如何解决带有 PHP 的 Google 身份验证器不起作用
我正在尝试使用项目 https://github.com/sonata-project/GoogleAuthenticator 我首先安装了该项目: composer require sonata-project/google-authenticator 。 在此之后,当我想查看操作时收到错误
PHP 致命错误:在第 19 行的 /home/######/vendor/sonata-project/google-authenticator/src/GoogleAuthenticator.php 中找不到接口“Sonata\GoogleAuthenticator\GoogleAuthenticatorInterface”
我是不是忘记了什么?
任何帮助将不胜感激!
解决方法
我想你已经解决了这个问题,或者以某种方式绕过了它。但我的答案正在改变
include_once __DIR__.'/src/FixedBitNotation.php';
include_once __DIR__.'/src/GoogleAuthenticator.php';
include_once __DIR__.'/src/GoogleQrUrl.php';
include_once __DIR__.'/src/FixedBitNotation.php';
include_once __DIR__.'/src/GoogleAuthenticatorInterface.php';
include_once __DIR__.'/src/GoogleAuthenticator.php';
include_once __DIR__.'/src/GoogleQrUrl.php';
即添加:include_once __DIR__.'/src/GoogleAuthenticatorInterface.php';
版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。