Hi, I've been going bonkers trying to format the data from an RSS feed. The problem I'm having is with the image/text wrap. Is it possible to disable that?
I've been trying to sort it out server side with VBScript (it's on an ASP not PHP page), but I got some advice to ask you CSS types. Here's the code I'm currently using:
I'm more than happy to use any language (that works - even PHP if there's no other option, but I'm sure there must be!!) in order to perform this task.
I've been trying to sort it out server side with VBScript (it's on an ASP not PHP page), but I got some advice to ask you CSS types. Here's the code I'm currently using:
Code:
dim xmlDom, nodeCol, oNode, oChildNode
set xmlDom = Server.CreateObject("MSXML2.Domdocument.4.0")
call xmlDom.setProperty("ServerHTTPRequest", true)
xmlDom.async = false
call xmlDom.load("[URL unfurl="true"]http://www.postconflictheritage.com/home/pch_blog/rss.xml")[/URL]
if not xmlDom.documentElement is nothing then
set nodeCol = xmlDom.documentElement.selectNodes("channel/item")
for each oNode in nodeCol
Response.Write("<p>" & vbCrLf)
set oChildNode = oNode.selectSingleNode("title")
if not oChildNode is nothing then
Response.Write(" <h3>" & oChildNode.text & "</h3>" & vbCrLf)
end if
set oChildNode = oNode.selectSingleNode("pubDate")
if not oChildNode is nothing then
Response.Write(" » " & oChildNode.text & "<br />" & vbCrLf)
end if
set oChildNode = oNode.selectSingleNode("description")
if not oChildNode is nothing then
Response.Write(" " & oChildNode.text & "<br />" & vbCrLf)
end if
set oChildNode = oNode.selectSingleNode("link")
if not oChildNode is nothing then
Response.Write(" <br />" & vbCrLf)
Response.Write(" <a href=""" & oChildNode.text & """ target=""_blank"">")
Response.Write(" more..." & vbCrLf)
Response.Write(" </a>" & vbCrLf)
end if
Response.Write("</p>" & vbCrLf)
next
else
Response.Write("<p>" & vbCrLf)
Response.Write(" Sorry, no news today!" & vbCrLf)
Response.Write("</p>" & vbCrLf)
end if