简体   繁体   English

如何在没有Windows身份验证的情况下通过php获取当前登录的Windows用户名

[英]how to get current logged windows username by php without windows authentication

how to get current logged windows username by php without windows authentication? 如何在没有Windows身份验证的情况下通过php获取当前登录的Windows用户名?

I tried use javascript, but it need to enable one setting in the IE browser, it's not possible to ask all users to do that. 我尝试使用javascript,但需要在IE浏览器中启用一项设置,因此不可能要求所有用户都这样做。

any other solutions? 还有其他解决方案吗?

my application is in DMZ, AD server in the intranet, there are in different domain.. 我的应用程序位于DMZ,Intranet中的AD服务器中,位于不同的域中。

Current User: <?php echo getenv("username"); ?> 当前用户: <?php echo getenv("username"); ?> <?php echo getenv("username"); ?>

List of the environment variables : <?php global $_ENV; var_dump($_ENV); ?> 环境变量列表: <?php global $_ENV; var_dump($_ENV); ?> <?php global $_ENV; var_dump($_ENV); ?>

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM