Thanks to visit codestin.com Credit goes to github.com
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
\PhalApi\Tool::getClientIp(); 获取IP时,可能存在不唯一的情况,在本地多次反向代理后,会把 ,127.0.0.1 也加上了。 通常我们需要取唯一的IP地址,而不是数据 故需要取数据的第0个值。
The text was updated successfully, but these errors were encountered:
感谢提醒。
目前有两个解决方案: 方案1、在本地配置反向代理时,取消把【 ,127.0.0.1】也加上 方案2、再封装一个获取IP的方法,兼容处理多个IP的情况
此外,\PhalApi\Tool::getClientIp(); 后续会再看下如何调整和兼容。
Sorry, something went wrong.
No branches or pull requests
\PhalApi\Tool::getClientIp();
获取IP时,可能存在不唯一的情况,在本地多次反向代理后,会把 ,127.0.0.1 也加上了。
通常我们需要取唯一的IP地址,而不是数据
故需要取数据的第0个值。
The text was updated successfully, but these errors were encountered: