使用ASP控制指定站点解析脚本语言函数
程序员文章站
2023-11-29 18:01:04
============================================================= '  ...
=============================================================
' 感谢您使用asp001工作室开发的实用函数程序
' http://www.asp001.net
'=============================================================
'asp001工作室为您提供订制程序开发、企业互联网拓展服务
'qq:1974229
'e-mail:shenyangchuqi@tom.com
'更多程序下载请到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
' 感谢您使用asp001工作室开发的实用函数程序
' http://www.asp001.net
'=============================================================
'asp001工作室为您提供订制程序开发、企业互联网拓展服务
'qq:1974229
'e-mail:shenyangchuqi@tom.com
'更多程序下载请到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
推荐阅读