php set user environment using cli on windows
<p>I am trying to set a user environment variable, but couldn't find a solution to achieve this.
I am able to read a user environment variable with:</p>

<pre><code>$WshShell = new COM("WScript.Shell");
$WshEnv = $WshShell-&gt;Environment("USER");
$tempPath = $WshEnv-&gt;Item("TEMP");
</code></pre>

<p>But how can I set a variable if I would like to use COM at php?</p>
