0

How might one dynamically generate a temporary RSS feed, on the fly, from a list of links that point to videos, for example?

Benjamin Allison
  • 2,134
  • 3
  • 30
  • 55

1 Answers1

0

Check the specifications for RSS-feeds, e.g. here:

http://www.rss-specifications.com/ or http://www.atomenabled.org/developers/syndication/atom-format-spec.php, there's tons, just check Google.

Then iterate through your list and build the appropriate XML.

Select0r
  • 12,234
  • 11
  • 45
  • 68
  • Yeah, the format for an RSS feed is simple enough; I guess what I'm wondering is, can build an XML file "on the fly" with php or javascript? – Benjamin Allison Sep 01 '10 at 16:04
  • Hmmm... here's the thing though: the list of links that I want to base the RSS on from text in a Wordpress post. And, this text will change so the XML needs to be generated temporarily/on the fly. A user hits the page, reads the post, which contains links, and then has the option to Download to Ipod. This is needs to happen as a "podcast" so that all the videos are grouped together in iTunes, etc. But again, it needs to be temporary, since the content might change. – Benjamin Allison Sep 02 '10 at 13:45
  • Link you "Download to iPod"-link to a PHP-file which will generate the XML-file and send it to the browser with the content-type "application/rss+xml" (as Kwebble wrote). – Select0r Sep 02 '10 at 14:06
  • Nice! So, will XML files simply accumulate on the server, or can they be "temporary"? Also, not to be a leech, but are there any good tuts to get me started on creating files server side? I'm very junior as far as PHP goes. :) Regardless, thanks all! – Benjamin Allison Sep 02 '10 at 14:13
  • XML "files" are not created at all if you do it this way, the PHP-file will just "deliver" the XML, nothing accumulates. To get started with PHP, get some books, google tutorials, learn by doing. – Select0r Sep 02 '10 at 18:27