viewpoint-particle

Author Topic: RSS'ing the new forum  (Read 6236 times)

stanl

  • Pundit
  • *****
  • Posts: 759
RSS'ing the new forum
« on: June 05, 2013, 09:35:06 am »
I assume someone has a script to do this; if not I may have something in my archives to get started.
 
or maybe a PS two-liner via WB 2013 CLR:
Code: [Select]
$url = "http://forum.winbatch.com/index.php?action=.xml;type=rss
Invoke-RestMethod $url | Select Title, Link

Deana

  • Wilson WindowWare Tech Support
  • Pundit
  • *****
  • Posts: 1183
  • WinBatch® can do it.
    • WinBatch Tech Support Database
Re: RSS'ing the new forum
« Reply #1 on: June 05, 2013, 09:52:17 am »
Here is another option using COM Automation:

Code: Winbatch
strURL="http://forum.winbatch.com/index.php?action=.xml;type=rss"
rssfeedfile = DirScript():"WBFeed.xml"
objHTTP = ObjectCreate("MSXML2.XMLHTTP")
objHTTP.Open("GET", strURL, @FALSE)
objHTTP.Send()
rssfeeddata = objHTTP.ResponseText
;Pause('rssfeeddata', rssfeeddata)
FilePut( rssfeedfile, rssfeeddata )
Run(rssfeedfile,"")
Exit
 
Deana F.
Technical Support
Wilson WindowWare Inc.

stanl

  • Pundit
  • *****
  • Posts: 759
Re: RSS'ing the new forum
« Reply #2 on: June 06, 2013, 06:44:13 am »
Here is another option using COM Automation:
Nice, but that still leaves the parsing to more coding. The CLR route can break down the individual elements from the pipeline and this shows off the 'neatness' of WB2013.
I haven't played with RSS for 2 years, but this looks like a nice spare-time project as this new board supports RSS.

stanl

  • Pundit
  • *****
  • Posts: 759
Re: RSS'ing the new forum
« Reply #3 on: June 07, 2013, 06:31:25 am »
Been trying to extract the posts in a GridView. Issue is with the description tag which holds CDATA. If I pipe it as | title, link, description I only get "description" as output. However, if I call
rss.item.description I get the CDATA.
 
Seems like xPath is the alternative. :'(