將你的網(wǎng)站設(shè)置為客戶的信任網(wǎng)站--WSH方案
發(fā)表時(shí)間:2023-08-09 來(lái)源:明輝站整理相關(guān)軟件相關(guān)文章人氣:
[摘要]將代碼存為TrustedSite.js,在客戶端執(zhí)行 var SiteName="Acmnet"SetTrustSite(SiteName);WScript.Echo("...
將代碼存為TrustedSite.js,在客戶端執(zhí)行
var SiteName="Acmnet"
SetTrustSite(SiteName);
WScript.Echo("You have accept 'http://acmnet/' as your Trusted Site");
function SetTrustSite(StrSiteName)
{
var WshShell=WScript.CreateObject("WScript.Shell");
WshShell.RegWrite("HKEY_CURRENT_USER\\Software\\Microsoft\\Windows\\CurrentVersion\\Internet Settings\\ZoneMap\\Domains\\"+StrSiteName+"\\http", 2 ,"REG_DWORD");
TrustedSite_Value=WshShell.RegRead("HKEY_CURRENT_USER\\Software\\Microsoft\\Windows\\CurrentVersion\\Internet Settings\\ZoneMap\\Domains\\"+StrSiteName+"\\http");
delete WshShell;
}