将代码存为trustedsite.js,在客户端执行
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;
}
