How might one dynamically generate a temporary RSS feed, on the fly, from a list of links that point to videos, for example?
A:
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
2010-09-01 15:39:40
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
2010-09-01 16:04:34
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
2010-09-02 13:45:06
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
2010-09-02 14:06:08
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
2010-09-02 14:13:03
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
2010-09-02 18:27:29
Sweet. Makes sense! Thanks.
Benjamin Allison
2010-09-02 18:46:05
Feel free to accept my answer then ;)
Select0r
2010-09-03 09:06:05