npm : The file cannot be loaded C:\Program Files\NodeJS\npm.ps1 because it is forbidden to run scripts on this system. For more information, see about_execution_policies in https:/go.microsoft.com/fwlink/?LinkId=135170.
1. npm : The file cannot be loaded c:\program files\nodejs\npm.ps1 because the script is prohibited from running on this system. For more information, see about_execution_policies in https:/go.microsoft.com/fwlink/?LinkId=135170.
PS C:\wwwroot\phpMyAdmin> npm -v
npm : 无法加载文件 C:\Program Files\nodejs\npm.ps1,因为在此系统上禁止运行脚本。有关详细信息,请参阅 https:/go.microsoft.com/fwlink/?LinkID=135170 中的 about_Execution_Policies。
所在位置 行:1 字符: 1
+ npm -v
+ ~~~
+ CategoryInfo : SecurityError: (:) [],PSSecurityException
+ FullyQualifiedErrorId : UnauthorizedAccess
2. Confirm that the file C:\Program Files\NodeJS\npm.ps1 exists. as shown in Figure 1
3. Enter one of the following commands to change the execution policy, which is permanently changed (valid for all sessions). as shown in Figure 2
PS C:\wwwroot\phpMyAdmin> Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Force
PS C:\wwwroot\phpMyAdmin> npm -v
10.9.2
PS C:\wwwroot\phpMyAdmin>

