How will I parse this XML using jQuery?


<pubDate>Mon, 27 Dec 2010 10:48:28 PST</pubDate>

I have to display month and date separately..

Write a javascript function which will accept the above xml as a parameter and than parse the xml using jquery.

function parseItemXML(itemXML){		
		$(itemXML).find('item').each(function(){//For each item element in the xml
			var showDateTxt = $(this).find('showDate').text(); //get the date
			var showDate = $.datepicker.parseDate( "mm/dd/yy", showDateTxt); //parse the date using the datapicker jquery ui component
			alert("Date:"+showDate.getDate()+" Month:"+(showDate.getMonth()+1));