Filen bliver ikke oprettet!
Hej Eksperter,Hvorfor bliver denne her fil ikke oprettet på mit webhotel?
<!--#INCLUDE file="Includes/db.inc" -->
<%
Call opendb()
Call opentbl("SELECT * FROM page", rs)
if not rs.eof then
%>
<%
function RSSWrite()
strRSS = ""
strRSS = strRSS & "<?xml version=""1.0"" encoding=""UTF-8""?>" & VbCrLf
strRSS = strRSS & " <urlset xmlns=""http://www.google.com/schemas/sitemap/0.84"">" & VbCrLf
strRSS = strRSS & " <url>" & VbCrLf
strRSS = strRSS & " < loc>http://www.server.com/</loc>" & VbCrLf
strRSS = strRSS & " <lastmod>"&date&"</lastmod>" & VbCrLf
strRSS = strRSS & " <changefreq>weekly</changefreq>" & VbCrLf
strRSS = strRSS & " </url>" & VbCrLf
do while not rs.eof
strRSS = strRSS & " <url>" & VbCrLf
strRSS = strRSS & " < loc>http://www.server.com/information.asp?page="&rs("page_id")&"&print=print</loc>" & VbCrLf
strRSS = strRSS & " <lastmod>"&rs("oprettet")&"</lastmod>" & VbCrLf
strRSS = strRSS & " <changefreq>weekly</changefreq>" & VbCrLf
strRSS = strRSS & " </url>" & VbCrLf
rs.movenext
loop
strRSS = strRSS & "</urlset>"
Dim fso, MyFile
Set fso = CreateObject("Scripting.FileSystemObject")
Set MyFile = fso.CreateTextFile(Request.ServerVariables("http:\\www.server.com") & "\sitemap.xml", True)
MyFile.Write(strRSS)
MyFile.Close
end function
end if
Call closetbl(rs)
Call closedb()
%>
