The new cloud Management System Version 3.0 Google map builder is provided, tested, and easy to use.

Source: Internet
Author: User

New cloud management system Google map builder for v3.0

I don't need to say much about its benefits, but I need to declare that the program is something in the official commercial version. Before Version 3.0, it only became effective for websites on HTML pages and only allowed to generate articles and download channels.

2.1 demo address: http://code.feyu.cn/sitemap.xml

3.0 demo address: http://www.feyu.cn/sitemap.xml

Last modified ASP to dynamically generate a map

Demo address: http://vip.feyu.cn/sitemap.xml

As long as extract to the root directory of the website, run it on the line, and then go to GG website management background (https://www.google.com/accounts/ServiceLogin? Service = sitemaps & hl = zh_CN & continue = https % 3A % 2F % 2Fwww.google.com % 2 Fwebmasters % 2 Ftools % 2 Fsiteoverview & nui = 1) submit http: // your url/sitemap. xml is enough.

It is best to establish a connection to the program in the background. After each update, the program will be generated in the background.Copy codeThe Code is as follows: <! -- # Include file = "conn. asp" -->
<! -- # Include file = "inc/const. asp" -->
<%
Server. ScriptTimeout = 50000

Dim Rs, SQL, XMLContent, Thisurl
Dim CreateHtml, ChannelRootDir, ChannelID
Dim XMLDOM, node, Cnode, Cnode1, msginfo

Thisurl = "http: //" & Request. ServerVariables ("HTTP_HOST ")

'Response. Clear
'Response. CharSet = "UTF-8"
'Response. ContentType = "text/xml"

Call IndexSiteMap ("/")
'Call ChannelSiteMap ("./")

'Response. Write XMLContent
'Response. Write Newasp. FormatDate (now, 2)

Sub IndexSiteMap (strPath)
XMLContent = "<? Xml version = '1. 0' encoding = 'utf-8'?> "& VbNewLine
XMLContent = XMLContent & "<urlset xmlns =" "http://www.google.com/schemas/sitemap/0.84"> "& vbNewLine
XMLContent = XMLContent & "<url>" & vbNewLine
XMLContent = XMLContent & "<loc>" & Thisurl & "/</loc>" & vbNewLine & "<lastmod>" & Newasp. formatDate (Now (), 2) & "</lastmod>" & vbNewLine & "<changefreq> daily </changefreq>" & vbNewLine & "<priority> 1.0 </priority>" & vbNewLine
XMLContent = XMLContent & "</url>" & vbNewLine
LoadSitemap 2, 0
LoadSitemap 1, 0
XMLContent = XMLContent & "</urlset>"
StrPath = Server. MapPath (strPath) & "\ sitemap. xml"
CreateXMLFile XMLContent, strPath
Response. Write "site map generated successfully! "
End Sub

Sub ChannelSiteMap (strPath)
XMLContent = "<? Xml version = '1. 0' encoding = 'utf-8'?> "& VbNewLine
XMLContent = XMLContent & "<urlset xmlns =" "http://www.google.com/schemas/sitemap/0.84"> "& vbNewLine
XMLContent = XMLContent & "<url>" & vbNewLine
XMLContent = XMLContent & "<loc>" & Thisurl & "/code/</loc>" & vbNewLine & "<lastmod>" & Now () & "</lastmod>" & vbNewLine & "<changefreq> daily </changefreq>" & vbNewLine & "<priority> 1.0 </priority>" & vbNewLine
XMLContent = XMLContent & "</url>" & vbNewLine
LoadSitemap 2, 11
XMLContent = XMLContent & "</urlset>"
StrPath = Server. MapPath (strPath) & "\ sitemap. xml"
CreateXMLFile XMLContent, strPath
Response. Write "site map generated successfully! "
End Sub

Function LoadSitemap (ByVal sid, ByVal chanid)
Chanid = Newasp. ChkNumeric (chanid)
Dim FindOrder, TableName
If sid = 1 Then
TableName = "[NC_Article]"
FindOrder = "order by a. WriteTime DESC, A. ArticleID DESC"
SQL = "A. ArticleID, A. ClassID, A. ChannelID, A. WriteTime, A. HtmlFileDate ,"
Else
TableName = "[NC_SoftList]"
FindOrder = "order by a. SoftTime DESC, A. SoftID DESC"
SQL = "A. SoftID, A. ClassID, A. ChannelID, A. SoftTime, A. HtmlFileDate ,"
End If
If chanid = 0 Then
SQL = "select top 3000" & SQL & "C. htmlFileDir, B. channelDir, B. isCreateHtml, B. htmlExtName FROM ("& TableName &" a inner join [NC_Classify] C On. classID = C. classID) inner join [NC_Channel] B On. channelID = B. channelID where. isAccept> 0 "& FindOrder
Else
SQL = "SELECT" & SQL & "C. htmlFileDir, B. channelDir, B. isCreateHtml, B. htmlExtName FROM ("& TableName &" a inner join [NC_Classify] C On. classID = C. classID) inner join [NC_Channel] B On. channelID = B. channelID where. channelID = "& chanid &" And. isAccept> 0 "& FindOrder
End If
Set Rs = Newasp. Execute (SQL)
If Rs. BOF And Rs. EOF Then
Else
CreateHtml = 1 'rs ("IsCreateHtml ")
Do While Not Rs. EOF
Call LoadSoftList ()
Rs. MoveNext
Loop
End If
Rs. Close: Set Rs = Nothing
End Function

Sub LoadSoftList ()
Dim HtmlFileName, LinksUrl, strLinksUrl
ChannelID = Rs (2)
Newasp. LoadChannel (ChannelID)
ChannelRootDir = Newasp. ChannelPath
CreateHtml = Newasp. ChannelUseHtml
If CInt (CreateHtml) <> 0 Then
LinksUrl = Newasp. readDestination (Newasp. m_InfoDestination, Newasp. m_ChannelDir, Rs ("HtmlFileDate"), Rs ("HtmlFileDir"), Rs ("ClassID"), Rs (0), 1 ,"")
Else
If IsURLRewrite Then
LinksUrl = ChannelRootDir & Rs (0) & Newasp. ChannelHtmlExt
Else
LinksUrl = ChannelRootDir & "show. asp? Id = "& Rs (0)
End If
End If
StrLinksUrl = "<url>" & vbNewLine
StrLinksUrl = strLinksUrl & "<loc>" & Thisurl & LinksUrl & "</loc>" & vbNewLine & "<lastmod>" & Newasp. formatDate (Rs (3), 2) & "</lastmod>" & vbNewLine & "<changefreq> daily </changefreq>" & vbNewLine & "<priority> 1.0 </priority>" & vbNewLine
StrLinksUrl = strLinksUrl & "</url>" & vbNewLine
XMLContent = XMLContent & strLinksUrl
End Sub
'================================================ ==========
'Function name: CreateXMLFile
'Usage: Create an XML file
'Parameter: XmlStr ---- XML string
'Formpath ---- path of the created File
'================================================ ==========
Function CreateXMLFile (sXML, FilePath)
Dim objXML
If InStr (FilePath, ":") = 0 Then FilePath = Server. MapPath (FilePath)
Set objXML = Server. CreateObject ("MSXML2.DOMDocument. 3.0 ")
If objXML. LoadXml (sXML) Then
ObjXML. Save (FilePath)
End If
Set objXML = Nothing
End Function
%>

Local download

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.