PHP5调用win系统com组件查看用户信息
程序员文章站
2022-05-26 15:51:33
...
php5
/*---------用户组信息*/
$computer=new COM("WinNT://.");
$computer->Filter=array("User");
echo "User:
";
foreach($computer as $user){
echo "
// getUserInfo($user->Name);
echo "
";
}
echo "UserGroup:
";
$computer->Filter=array("Group");
foreach($computer as $group){
echo "
echo $group->Description."
";
}
echo "
无名氏作品";
PHP5 FOR WINXP/2K 测试通过~ 呵呵~~ 主要是采用 php com函数调用系统组件实现的~~不过 这个函数有点危险性~~