<% response.ContentType="text/xml" Set Conn = Server.CreateObject("ADODB.Connection") Set rs = Server.CreateObject("ADODB.Recordset") Conn.Open("DRIVER={MySQL ODBC 3.51 Driver}; SERVER=79.170.40.41;DATABASE=web41-stmmenston;Port=3306;UID=web41-stmmenston;Pwd=RhFVhtFhx; OPTION=3") rs.ActiveConnection = Conn rs.cursorlocation=3 rs.cursortype=2 rs.locktype=3 rs.Open "SELECT * FROM rssfeed ORDER BY id DESC" Function GetW3DTF(dtmDate) Dim strDate strDate = DatePart("yyyy", dtmDate) & "-" & DatePart("m", dtmDate) & "-" & DatePart("d", dtmDate) & " " &_ DatePart("h", dtmDate) & ":" & DatePart("n", dtmDate) & ":" & DatePart("s", dtmDate) GetW3DTF = strDate End Function Function return_RFC822_Date(myDate, offset) Dim myDay, myDays, myMonth, myYear Dim myHours, myMonths, mySeconds myDate = CDate(myDate) myDay = WeekdayName(Weekday(myDate),true) myDays = Day(myDate) myMonth = MonthName(Month(myDate), true) myYear = Year(myDate) myHours = zeroPad(Hour(myDate), 2) myMinutes = zeroPad(Minute(myDate), 2) mySeconds = zeroPad(Second(myDate), 2) return_RFC822_Date = myDay&", "& _ myDays&" "& _ myMonth&" "& _ myYear&" "& _ myHours&":"& _ myMinutes&":"& _ mySeconds&" "& _ offset End Function Function zeroPad(m, t) zeroPad = String(t-Len(m),"0")&m End Function %> St Mary's Menston RSS Feed http://www.stmarysmenston.com Our Latest News> en-us<%do while not rs.eof%> <![CDATA[<%=server.htmlencode(rs("title"))%>]]> ]]> <%sDate = GetW3DTF(rs("pubdate")) sDate = return_RFC822_Date(sDate,"GMT") response.write ""%> ]]> ]]> <%rs.movenext loop%>