=============================================================
' 感謝您使用ASP001工作室開發的實用函數程序
' HTTP://WWW.ASP001.NET
'=============================================================
'ASP001工作室為您提供訂制程序開發、企業互聯網拓展服務
'QQ:1974229
'E-Mail:
[email protected] '更多程序下載請到HTTP://WWW.ASP001.NET
'=============================================================
'函數介紹:設置指定站點支持腳本語言
'本函數使用ADSI,需要Administrators組用戶權限
'函數名稱:AdminAegis (Computer,SiteNum)
'程序開發:ASP001工作室 ChuQi
'用法:AdminAegis 計算機名,站點編號
'例:AdminAegis "127.0.0.1","2"
'=============================================================
Function AdminAegis(Computer,SiteNum)
Set IIsWebServiceObj = GetObject("IIS://"&Computer&"/W3SVC/"&SiteNum)
dim Aegis(1)
Aegis(0)=".asp,C:\WINNT\system32\inetsrv\asp.dll,5,GET,HEAD,POST,TRACE"
'Aegis(1)=".aspx,C:\WINNT\Microsoft.NET\Framework\v1.1.4322\aspnet_isapi.dll,1,GET,HEAD,POST,DEBUG"
'解析其它文件請同樣使用Aegis(Num)=""這種格式,記得要將dim Aegis(Num)定義
'.htw,C:\WINNT\system32\webhits.dll,3,GET,HEAD,POST
'.ida,C:\WINNT\system32\idq.dll,7,GET,HEAD,POST
'.idq,C:\WINNT\system32\idq.dll,7,GET,HEAD,POST
'.asp,C:\WINNT\system32\inetsrv\asp.dll,5,GET,HEAD,POST,TRACE
'.cer,C:\WINNT\system32\inetsrv\asp.dll,5,GET,HEAD,POST,TRACE
'.cdx,C:\WINNT\system32\inetsrv\asp.dll,5,GET,HEAD,POST,TRACE
'.asa,C:\WINNT\system32\inetsrv\asp.dll,5,GET,HEAD,POST,TRACE
'.idc,C:\WINNT\system32\inetsrv\httpodbc.dll,5,GET,POST<br>
'.shtm C:\WINNT\system32\inetsrv\ssinc.dll,5,GET,POST<br>
'.shtml C:\WINNT\system32\inetsrv\ssinc.dll,5,GET,POST<br>
'.stm C:\WINNT\system32\inetsrv\ssinc.dll,5,GET,POST<br>
'.asax C:\WINNT\Microsoft.NET\Framework\v1.1.4322\aspnet_isapi.dll,5,GET,HEAD,POST,DEBUG
'.ascx,C:\WINNT\Microsoft.NET\Framework\v1.1.4322\aspnet_isapi.dll,5,GET,HEAD,POST,DEBUG
'.ashx,C:\WINNT\Microsoft.NET\Framework\v1.1.4322\aspnet_isapi.dll,1,GET,HEAD,POST,DEBUG
'.asmx,C:\WINNT\Microsoft.NET\Framework\v1.1.4322\aspnet_isapi.dll,1,GET,HEAD,POST,DEBUG
'.aspx,C:\WINNT\Microsoft.NET\Framework\v1.1.4322\aspnet_isapi.dll,1,GET,HEAD,POST,DEBUG
'.axd,C:\WINNT\Microsoft.NET\Framework\v1.1.4322\aspnet_isapi.dll,1,GET,HEAD,POST,DEBUG
'.vsdisco,C:\WINNT\Microsoft.NET\Framework\v1.1.4322\aspnet_isapi.dll,1,GET,HEAD,POST,DEBUG
'.rem,C:\WINNT\Microsoft.NET\Framework\v1.1.4322\aspnet_isapi.dll,1,GET,HEAD,POST,DEBUG
'.soap,C:\WINNT\Microsoft.NET\Framework\v1.1.4322\aspnet_isapi.dll,1,GET,HEAD,POST,DEBUG
'.config,C:\WINNT\Microsoft.NET\Framework\v1.1.4322\aspnet_isapi.dll,5,GET,HEAD,POST,DEBUG
'.cs,C:\WINNT\Microsoft.NET\Framework\v1.1.4322\aspnet_isapi.dll,5,GET,HEAD,POST,DEBUG
'.csproj,C:\WINNT\Microsoft.NET\Framework\v1.1.4322\aspnet_isapi.dll,5,GET,HEAD,POST,DEBUG
'.vb,C:\WINNT\Microsoft.NET\Framework\v1.1.4322\aspnet_isapi.dll,5,GET,HEAD,POST,DEBUG
'.vbproj,C:\WINNT\Microsoft.NET\Framework\v1.1.4322\aspnet_isapi.dll,5,GET,HEAD,POST,DEBUG
'.webinfo,C:\WINNT\Microsoft.NET\Framework\v1.1.4322\aspnet_isapi.dll,5,GET,HEAD,POST,DEBUG
'.licx,C:\WINNT\Microsoft.NET\Framework\v1.1.4322\aspnet_isapi.dll,5,GET,HEAD,POST,DEBUG
'.resx,C:\WINNT\Microsoft.NET\Framework\v1.1.4322\aspnet_isapi.dll,5,GET,HEAD,POST,DEBUG
'.resources,C:\WINNT\Microsoft.NET\Framework\v1.1.4322\aspnet_isapi.dll,5,GET,HEAD,POST,DEBUG
IIsWebServiceObj.ScriptMaps=Aegis
IIsWebServiceObj.SetInfo
'顯示支持腳本語言
response.write "當前站點支持解析列表:<br>"
For ValueIndex = 0 To UBound(IIsWebServiceObj.ScriptMaps)
response.write IIsWebServiceObj.Get("ScriptMaps")(ValueIndex)
response.write "<br>"
Next
End Function