访问注册表使用PHP和DOTNET类注册表、PHP、DOTNET

2023-09-03 06:34:52 作者:酒盏

这是一个简单的问题:我如何访问Windows的注册表与PHP和DOTNET类?我想要做的就是读取值到另一个程序中写道。

This is a simple question: How do I access Windows' registry with PHP and the DOTNET class? What I want to do is to read a value that another program wrote.

谷歌搜索并没有透露太多。我AP preciate任何回答!

Googling did not reveal much. I appreciate any answer!

推荐答案

我找到了答案,它与COM对象:

I found the answer, it works with the COM object:

$wscript = new COM('WScript.Shell');
$a = $wscript->RegRead('HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\etc');
var_dump($a->value);