新云软件园:请安心下载,绿色无病毒!

软件提交最近更新热门排行
您现在的位置:首页››编程教学››ASP教程››ASP应用

Google SiteMap 生成工具

2005-08-24 02:38作者:未知来源:未知浏览:1965 评论:0
<%
' sitemap_gen.asp
' A simple script to automatically produce sitemaps for a webserver, in the Google Sitemap Protocol (GSP)
' by Francesco Passantino
' www.iteam5.net/francesco/sitemap
' v0.2 released 5 june 2005 (Listing a directory tree recursively improvement)
'
' BSD 2.0 license,
'http://www.opensource.org/licenses/bsd-license.php


session("server")="http://www.xxx.com" '你的域名
vDir = "/blueidea" '制作SiteMap的目录,相对目录(相对于根目录而言)


set objfso = CreateObject("Scripting.FileSystemObject")
root = Server.MapPath(vDir)

response.ContentType = "text/xml"
response.write "<?xml version='1.0' encoding='UTF-8'?>"
response.write "<urlset xmlns=http://www.google.com/schemas/sitemap/0.84'>;"

Set objFolder = objFSO.GetFolder(root)
'response.write getfilelink(objFolder.Path,objFolder.dateLastModified)
Set colFiles = objFolder.Files
For Each objFile In colFiles
response.write getfilelink(objFile.Path,objfile.dateLastModified)
Next
ShowSubFolders(objFolder)

response.write "</urlset>"
set fso = nothing


Sub ShowSubFolders(objFolder)
Set colFolders = objFolder.SubFolders
For Each objSubFolder In colFolders
if folderpermission(objSubFolder.Path) then
response.write getfilelink(objSubFolder.Path,objSubFolder.dateLastModified)
Set colFiles = objSubFolder.Files
For Each objFile In colFiles
response.write getfilelink(objFile.Path,objFile.dateLastModified)
Next
ShowSubFolders(objSubFolder)
end if
Next
End Sub


Function getfilelink(file,datafile)
file=replace(file,root,"")
file=replace(file,"\","/")
If FileExtensionIsBad(file) then Exit Function
if month(datafile)<10 then filedatem="0"
if day(datafile)<10 then filedated="0"
filedate=year(datafile)&"-"&filedatem&month(datafile)&"-"&filedated&day(datafile)
getfilelink = "<url><loc>"&server.htmlencode(session("server")&vDir&file)&"</loc><lastmod>"&filedate&"</lastmod><changefreq>daily</changefreq><priority>1.0</priority></url>"
Response.Flush
End Function


Function Folderpermission(pathName)

'需要过滤的目录(不列在SiteMap里面)
PathExclusion=Array("\temp","\_vti_cnf","_vti_pvt","_vti_log","cgi-bin")
Folderpermission =True
for each PathExcluded in PathExclusion
if instr(ucase(pathName),ucase(PathExcluded))>0 then
Folderpermission = False
exit for
end if
next
End Function


Function FileExtensionIsBad(sFileName)
Dim sFileExtension, bFileExtensionIsValid, sFileExt
'modify for your file extension http://www.googleguide.com/file_type.html)
Extensions = Array("png","gif","jpg","jpeg","zip","pdf","ps","html","htm","asp","php","wk1","wk2","wk3","wk4","wk5","wki","wks","wku","lwp","mw","xls","ppt","doc","swf","wks","wps","wdb","wri","rtf","ans","txt")
'设置列表的文件名,扩展名不在其中的话SiteMap则不会收录该扩展名的文件

if len(trim(sFileName)) = 0 then
FileExtensionIsBad = true
Exit Function
end if

sFileExtension = right(sFileName, len(sFileName) - instrrev(sFileName, "."))
bFileExtensionIsValid = false 'assume extension is bad
for each sFileExt in extensions
if ucase(sFileExt) = ucase(sFileExtension) then
bFileExtensionIsValid = True
exit for
end if
next
FileExtensionIsBad = not bFileExtensionIsValid
End Function
%>
Tags:责任编辑:cvery
顶一下(57)
91.94%
    1. 中国地图20152015中国地图

      新云下载给大家提供的中国地图2015下载包含有中国地图全图大图高清版、中国地图全图各省高清版、中国地图全图2015、中国地图电子版2015、中国竖版地图2015等等,有这方面的需要的欢迎来新云网络下载!...

    1. 谷歌软件谷歌软件

      谷歌软件合集包含与谷歌相关大量实用软件,欢迎下载试用。

    1. 地图软件合集地图软件合集

      本篇为您整理出地图软件合集,包含各种地图,如百度、谷歌、欧洲、日本等地图。

    文章评论 新云下载QQ群:① 7551827使用手机微信搜索 微信号:xinyunshouyou 关注我们 有更多惊喜!!

    请自觉遵守互联网相关政策法规,评论内容只代表网友观点,与本站立场无关!
      验证码:     登录   注册
    网友评论

    关注新云安卓游戏网

    旺彩彩票 www.7366.loan-海南七星彩手机投注| www.wz79.cc-七星彩网易开奖时间| www.884.org-快三猜大小不输| www.41869.com-中国购彩网登录地址| www.028511.com-送彩金彩票网站推荐| www.639365.cc-自助售彩终端机| www.036690.com-12快乐彩开奘结果| www.984957.com-北京时时彩停售时间| www.13yk.com-福利彩票计算器下载| www.096970.com-3d彩吧红星图库| www.222618.com-北京快三计划大小| www.178528.com-福彩网软件下载| www.749559.com-犀牛彩票app| www.969489.com-福彩3d内部绝密| www.80704.com-燕赵福彩3d走势图| www.551591.com-福彩三d试机号查询| www.838203.com-快三怎么定胆码| www.36038.com-网上彩票赔20万| www.383219.com-春天彩票软件| www.796964.com-彩博棋牌送彩金| www.025562.com-5分快三是哪里的| www.244659.com-彩票助手软件靠谱吗| www.556312.com-419彩票-| www.723908.com-中彩网乐和彩彩票| www.929735.com-全民彩票投注网| www.73xj.com-三地图谜牛彩网| www.121885.com-双色球走势图易彩网| www.205799.com-快三走势技巧| www.768393.com-时时彩开奖彩经网| www.927411.com-体彩直播室-| www.277366.com-湖北快三对应码| 大赢家彩票平台www.896165.com| www.6040.website福彩3d规律与技巧| www.31265.cc-爱乐透彩票新版| www.247662.com-凤凰彩票每天赚几百| www.750435.com-北京体彩网app| www.92el.com-平台计划师带你玩彩| www.6934.pw-七彩鱼怕开灯| www.25519.com-彩库助手-| www.132920.com-彩色混凝土压模价格| www.217692.com-五星彩票是骗局揭秘| www.cai1755.com彩7app-| www.sg56.com-时时彩豹子出号前兆| www.61or.com-一分快三预测分析| www.23657.cc-竞彩计算器官网| www.23029.com-988彩票网手机版| www.98241.com-腾讯三分彩稳定计划| www.304711.com-江苏快三走试图| www.558945.com-夸爱豆彩虹屁| www.kv94.com-爱彩乐是正规的吗| www.2rj.cc-金牛国际彩票| www.83wl.com-掌上购彩怎么提款| 500彩票www.26299z.com| www.9481.me-双色球彩票截止时间| 彩69www.022193.com| www.22ah.com-7168手机彩票| www.3733.site-彩票在线平台登录| www.42948.com-锋彩直播官网| www.024455.com-国彩彩票app下载| www.dn94.com-南方双彩网走势图| www.i42.me-昨晚的福利彩票号码| www.442797.com-福彩推荐专家预测| www.789099.com-足彩中奖是否真实| www.766877.com-nba篮彩推荐分析| www.8534.vip-360彩票网客户端| www.010895.com-易迅彩票app| www.cp986.com-福建快三开奖号码表| www.c89.com-国民彩票下载| www.37zy.com-彩铅画水滴详细教程| www.662.biz-福利彩票3d图片| www.5413.org-体彩超值8最新中奖| www.169085.com-湖北快三玩法| www.300057.com-贵卅快三基本走势图| www.369750.com-三分时彩下载安卓| www.32562.cc-足彩媒体预测总汇| www.83799.cc-苹果买彩票软件| www.039974.com-六彩票今晚开码多少| www.419040.com-印象彩票旧版本| www.5321.org-分分彩怎么杀号稳定| www.24473.com-古风女子彩铅画教程| www.81354.com-香港一彩吧-| www.72773.cc-竞彩彩民投注比例| www.554220.com-以防打彩票打错标语| www.692459.com-购彩大厅大发快3| www.795778.com-新加坡天天彩网站| www.884342.com-杏彩平台手机版登录| www.966440.com-彩经彩票手机下载| www.af70.com-昨天的彩票开奖号码| www.800337.com-幸运彩下载app| www.888174.com-万彩吧电脑版| www.967460.com-跟彩票有关的群名| 彩票58www.582909.com| www.vn02.com-博彩返水高的| www.58hr.cc-彩票界牛人-| www.334114.com-博大彩票能玩吗| www.567731.com-全民彩票购彩合法吗| www.651365.cc-摇骰子的彩票是什么| www.372168.com-体彩大乐透相关预测| www.555145.com-全民彩票软件| www.639169.com-体彩店老板怎么兑奖| www.737784.com-欢乐彩主播小小| www.825635.com-搏彩精英网址| www.897472.com-彩99是合法的吗| www.962429.com-彩票选什么号最好| www.sz1.com-香港168彩票网| www.2388.live-湖北快三胆码是什么| www.9534.cc-福彩是七位数吗| www.7111.biz-电玩8彩票网站| www.392051.com-关小刀足彩-| www.515504.com-南国七星彩-| www.uy11.com-湖北快三技巧口诀| www.610094.com-做梦梦到买彩票中奖| www.756787.com-中彩在线规则| www.890720.com-青岛福彩快三技巧| www.mt15.com-北京丹彩快三| www.12mw.com-18cp彩票网-| www.933045.com-快三购买平台| 网易彩票www.081wy.com| www.3520.cc-彩吧联盟1-| www.193786.com-河北快三今日推荐号| www.945168.com-腾讯10分彩-| 福彩www.2109u.com| www.031894.com-彩票网2044cm| www.183005.com-快购彩票3-| www.19660.com-彩软件下载-| www.ip60.com-105彩票网址| www.362443.com-吉林快三直选计划| www.435093.com-南宁福彩自助投注机| www.774758.com-彩78官网下载| www.840882.com-福利彩票中奖去哪领| www.914469.com-瑞彩祥云高级邀请码| www.968421.com-福建福彩网快3开奖| 奔驰彩票www.29178f.com| www.62283.cc-体彩大赢家足彩竞猜| www.974297.com-澳彩官方网站app| www.if44.com-今日彩票下载| www.640025.com-大通彩票网页手机版| www.905375.com-足彩网上投注app| www.33go.com-彩票晚上停售时间| www.4835.vip-彩票选六中五保五| www.336034.com-彩票新规则和玩法| www.960845.com-手机933彩票下载| www.2448.cm-江苏快三第一期几点| www.88844.com-彩票大师中心| www.246979.com-福彩3d中奖概率| www.803329.com-彩票开奖官网下载| www.897849.com-彩票店宣传语图片| www.960034.com-彩票一天出几回长龙| www.962913.com-三地彩圣字谜总汇| www.e27.com-来自旺彩大乐透社区| www.660372.cc-人工智能预测竞彩| www.768669.com-快3爱彩乐-| www.871593.com-利彩安全下载| www.971603.com-手机万豪彩票合法吗| www.kv3.cc-北京快三怎么玩挣钱| www.yf82.com-遵义市福彩中心地址| www.21616.com-5亿彩靠谱吗| www.38755.cc-福彩3d专家号| www.cai3222.com今日快三走势图| www.542896.com-彩票网站账户| www.604944.com-幸运中彩票旧版本| www.668745.com-中国城彩票-| www.728780.com-大连体彩中心官网| www.859709.com-泉州体彩音乐聊天|