pubDate from WordPress RSS feed won't display on my asp page

We have recently set up a WordPress blog in order to use the RSS feed to display news items on our asp webpage. I am using a bit of code we have used previously (and successfully) to display RSS feeds. However, the pubDate from the RSS feed will not display in any format - I can't seem to get it to write out anywhere on the page. The attached code contains 2 feeds - RSS1 is a feed of training events that works; RSS2 is the WordPress feed that isn't working.
<%
' =========== configuration for rolling box feeds=====================
' ##### URL to RSS Feed to display #########
URLToRSS1 = "http://ittraining.lse.ac.uk/xml/staffittraining.xml"
URLToRSS2 = "http://lseitnews.wordpress.com/feed/"
 
' ##### max number of displayed items #####
MaxNumberOfItems = 5
' ##### Item template.
' ##### {LINK} will be replaced with item link
' ##### {TITLE} will be replaced with item title
' ##### {DESCRIPTION} will be replaced with item description
' ##### {PUBDATE} will be replaced with date published
TrainingItemTemplate = "<p>{TITLE}<BR></p>"
ItemTemplate = "<p><em>{PUBDATE}</em><br /><strong>{TITLE}</strong><br /><em><a href=" & """{LINK}""" & " target='blank'>read more...</a></em><BR /></p>"
 
' ================================================
 
' =========== function to convert date=====================
 function convert(date)
 dim datearray
 date=left(date,10)
 datearray= split (date,"-")
 yearstr=datearray(0)
 monthstr=datearray(1)
 daystr=datearray(2)
 
 convert=Cdate(daystr &"/"& monthstr &"/"& yearstr)
 end function
 
'==========================================================
Set xmlHttp1 = Server.CreateObject("MSXML2.XMLHTTP.3.0")
Set xmlHttp2 = Server.CreateObject("MSXML2.XMLHTTP.3.0")
 
 
xmlHttp1.Open "Get", URLToRSS1, false
xmlHttp1.Send()
RSSXML1 = xmlHttp1.ResponseText
xmlHttp2.Open "Get", URLToRSS2, false
xmlHttp2.Send()
RSSXML2 = xmlHttp2.ResponseText
 
Set xmlDOM1 = Server.CreateObject("MSXML2.DomDocument.3.0")
Set xmlHttp2 = Nothing ' clear HTTP object
 
xmlDOM1.async = false
xmlDOM1.LoadXml(RSSXML1)
Set xmlDOM2 = Server.CreateObject("MSXML2.DomDocument.3.0")
xmlDOM2.async = false
xmlDOM2.LoadXml(RSSXML2)
 
Set xmlHttp1 = Nothing ' clear HTTP object
Set xmlHttp2 = Nothing ' clear HTTP object
 
Set RSSItems1 = xmlDOM1.getElementsByTagName("item") ' collect all "items" from downloaded RSS
Set xmlDOM1 = Nothing ' clear XML
Set RSSItems2 = xmlDOM2.getElementsByTagName("item") ' collect all "items" from downloaded RSS
Set xmlDOM2 = Nothing ' clear XML
 
RSSItemsCount1 = RSSItems1.Length-1
RSSItemsCount2 = RSSItems2.Length-1
 
j = -1
k = -1
%>
 
 
 
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML lang=en>
<HEAD><TITLE>IT Services</TITLE>
<META http-equiv=Content-Type content="text/html; charset=iso-8859-1">
<LINK media=screen href="http://www.lse.ac.uk/css/lse-strict.css" type=text/css rel=stylesheet>
<LINK media=screen href="http://www.lse.ac.uk/css/v3/itservices.css"type=text/css rel=stylesheet>
<base href="http://www.lse.ac.uk/itservices/" />
</HEAD>
 
 
<BODY>
<TABLE class=template-maintable cellSpacing=0 cellPadding=0 align=center summary="" border=0>
<TBODY> 
<TR>
<TD class=template-header><img src="http://www.lse.ac.uk/images/v3/itservices/header.jpg" alt="London School of Economics and Political Science" width="748" height="106"></TD>
</TR>
 
<TR>
<TD class=template-backgroundimage>
<TABLE class=template-secondarytable cellSpacing=0 cellPadding=0 width="920" align=center summary="" border=0>
<TBODY>
<TR>
<TD colSpan=7><IMG height=6 alt="" src="http://www.lse.ac.uk/images/v3/itservices/spacer.gif" width=3></TD></TR>
<TR>
<TD class=template-firstgutter><IMG height=3 alt="" src="http://www.lse.ac.uk/images/v3/itservices/spacer.gif" width=6></TD>
 
<!--Start of Left menu -->
 
<TD class=template-leftmenu vAlign=top>
 
 
<!--End of navigation boxes -->
 
<TABLE cellSpacing=0 cellPadding=0 width="100%" summary="" border=0><TBODY>
<TR>
<TD><IMG height=1 alt="" src="http://www.lse.ac.uk/images/v3/itservices/190line.gif" width=190></TD></TR></TBODY></TABLE>
 
<TABLE cellSpacing=0 cellPadding=5 width="100%" summary="" border=0><TBODY>
<TR>
<TD class=template-leftmenuindex><P class=template-margin-zero>
 <A href="http://www.lse.ac.uk/resources/siteIndex/">A-Z site index</A></P>
 </TD></TR></TBODY></TABLE>
            
<TABLE cellSpacing=0 cellPadding=0 width="100%" summary="" border=0><TBODY>
<TR>
<TD><IMG height=1 alt="" src="http://www.lse.ac.uk/images/v3/itservices/190line.gif" width=190></TD></TR></TBODY></TABLE>
 
<!--this is the search form start -->
<form method="GET" action="http://search.lse.ac.uk/search" name="searchForm" class="template-leftmenuindex">
              <div class="template-formmenuitem">
                <table cellspacing="0" cellpadding="5" border="0" summary>
                  <tr>
                    <td>
                      <input type="text" name="q" id="q" maxlength="256" value="Search" onFocus="this.value=''" size="20"></td>
                    <td class="nudge"><input type="image" src="http://www.lse.ac.uk/images/v3/itservices/go_button.gif" alt="GO" width="20" height="17"></td>
                  </tr>
                </table>
              </div>
              
<TABLE cellSpacing=0 cellPadding=0 width="100%" summary="" border=0><TBODY>
<TR>
<TD><IMG height=1 alt="" src="http://www.lse.ac.uk/images/v3/itservices/190line.gif" width=190></TD></TR></TBODY></TABLE>
<TABLE cellSpacing=0 cellPadding=5 width="100%" summary="" border=0><TBODY>
<TR>
<TD class=template-leftmenuindex>
<P class=small><input type="radio" value="" name="site">LSE</P></TD>
<TD class=template-leftmenuindex>
<p class="small"><input type="radio" value="itServices" checked="checked" name="site">IT Services</TD></TR></TBODY></TABLE>
<!--<input type="hidden" name="site" value="systest"> this hidden value is overridden/replaced by the 'site' radio button group-->
              <input type="hidden" name="output" value="xml_no_dtd">
              <input type="hidden" name="client" value="systest">
              <input type="hidden" name="proxystylesheet" value="systest">
 
</form>
 
<!--this is the search form end -->
 
 
<!--End of left column -->
 
 
 
 
<TD class=template-secondgutter><IMG height=3 alt="" src="http://www.lse.ac.uk/images/v3/itservices/spacer.gif" width=6></TD>
<!--Content area -->
 
<TD class=template-contentarea vAlign=top width="938"><A name=body></A>
            <H1 class=template-margin-top-zero>
            &nbsp;IT 
			Services</H1>
            <table width="98%" cellspacing="4" bordercolor="#808080" style="border-collapse: collapse" cellpadding="0">
              <tr>
                <td width="49%" valign="top" style="border-right-style: none; border-right-width: medium">
                &nbsp;</td>
                <td width="2%" valign="top" rowspan="2" style="border-left-style: solid; border-left-width: 1; border-right-style: none; border-right-width: medium">&nbsp;</td>
                <td width="49%" valign="top" rowspan="2" style="border-left-style: none; border-left-width: medium">
                <p class="big"><b>Latest news</b> </p>
                  <p>
                  
                  
                  <!--START OF NEWS FEED -->
 
<%                  
Number_of_Stories=0
For i = 0 To RSSItemsCount2
 
Set RSSItem2 = RSSItems2.Item(i)
		for each child in RSSItem2.childNodes
			Select case lcase(child.nodeName)
			case "title"
			RSStitle = child.text
			case "link"
			RSSlink = child.text
			case "pubDate" 
			RSSpubdate = child.text
			End Select
		next
 
 
'testing converting the date
'published=Rsspubdate
k = k+1
 	if k<MaxNumberOfItems then 
 		'if published > date - 1 and published < date + 7 then
		ItemContent = Replace(ItemTemplate,"{LINK}",RSSlink)
		ItemContent = Replace(ItemContent,"{PUBDATE}",FormatDateTime(RSSpubdate))
		ItemContent = Replace(ItemContent,"{TITLE}",RSSTitle)
		Response.Write ItemContent
		ItemContent = ""
		Number_of_Stories = Number_of_Stories + 1
		'end if
	End if
Next
%>
 
 
<!--END OF NEWS FEED -->
</p>
				<p>&nbsp;</p>
                  </td>
              </tr>
              <tr>
                <td width="49%" valign="top" style="border-right-style: none; border-right-width: medium">
                &nbsp;</td>
              </tr>
            </table>            
            <hr>
            <hr>
            <table width="100%" cellpadding="15" cellspacing="0" style="border-collapse: collapse" bordercolor="#111111">
              <tr>
                <td width="187" valign="top">
                <h4><strong>Free training courses running in the next 7 days</strong></h4>
                <p>
                <%
                      
                     
Number_of_Courses=0
For i = 0 To RSSItemsCount1
 
Set RSSItem1 = RSSItems1.Item(i)
		for each child in RSSItem1.childNodes
			Select case lcase(child.nodeName)
			case "title"
			RSStitle = child.text
			case "link"
			RSSlink = child.text
			case "ev:startdate"
			RSSstartdate=child.text
			End Select
		next
 
 
'testing converting the date
startdate=convert(Rssstartdate)
j = J+1
 	if J<MaxNumberOfItems then 
		if startdate > date and startdate < date + 7 then
		ItemContent = Replace(TrainingItemTemplate,"{LINK}",RSSlink)
		ItemContent = Replace(ItemContent,"{TITLE}",RSSTitle)
		Response.Write ItemContent
		ItemContent = ""
		Number_of_Courses = Number_of_Courses + 1
		end if
	End if
Next
 
 
'Response.End ' uncomment this line if you need to finalize output
%>
                </p>                  
                  <p align="right"><i><a href="http://ittraining.lse.ac.uk">course booking and more 
                  training options...</a></i></p>                  
                    </td>
                <td valign="top" bgcolor="#D2D9DE" width="187">
                &nbsp;</td>
              </tr>
            </table>
            <P> &nbsp;</p>
 
</TD>
 
 
 
 
<TD class=template-thirdgutter width="6"><IMG height=3 alt="" src="http://www.lse.ac.uk/images/v3/itservices/spacer.gif" width=6></TD>
</TR></TBODY></TABLE></TD></TR>
  
  
  
  
<TR>
<TD class=template-footer>
<TABLE cellSpacing=0 cellPadding=5 width="100%" align=left summary="" border=0>
<TBODY>
<TR>
<TD><IMG height=3 alt="" src="http://www.lse.ac.uk/images/v3/itservices/spacer.gif" width=4></TD>
<TD><A name=footer></A>
<P class=template-footertext><A href="http://www.lse.ac.uk/informationAbout/LSEWebsite/">About this site</A> | 
<A href="http://www.lse.ac.uk/feedback?type=about">About this page</A> | 
<A href="http://www.lse.ac.uk/feedback?type=comment">Comment on this page</A> </P>
 
<P class=template-footertext>Copyright © LSE. Use of this website is  subject to, and implies acceptance of, its (including 
<A href="http://www.lse.ac.uk/resources/termsOfUse/Default.htm#3">Copyright and intellectual property</A>, 
<A href="http://www.lse.ac.uk/resources/termsOfUse/Default.htm#5">Privacy and data protection</A>, and 
<A href="http://www.lse.ac.uk/resources/termsOfUse/Default.htm#7">Accessibility</A>).</P>
<P class=template-footertext>LSE, Houghton Street, London WC2A 2AE,UK; Tel: +44 (0)20 7405 7686</P></TD>
          <TD><IMG height=3 alt="" src="http://www.lse.ac.uk/images/v3/itservices/spacer.gif" 
            width=4></TD></TR></TBODY></TABLE>
			
			</TD></TR>
			
			
			</TBODY></TABLE></BODY></HTML>

Open in new window

LSE_IT_TrainingAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

dosthCommented:
hi

go to line no 182

change this case "pubDate"  to case "pubdate", you will get the date and time.

thanks
Dosth

0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
LSE_IT_TrainingAuthor Commented:
Wow, so simple. Many thanks!

Now that you've pointed it out, I think I understand why. Is it because the code uses this line:
Select case lcase(child.nodeName)?
0
dosthCommented:
yes, your are correct that line make the value to lower case

thanks
Dosth
0
LSE_IT_TrainingAuthor Commented:
Thanks very much for your help - it was driving me round the bend trying to figure out what was going on.
0
dosthCommented:
glad to help, yes some time thing make us crazy :)
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Web Languages and Standards

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.