Jump to content

Building an RSS feed with PHP


Fmdpa

Recommended Posts

I'm not very familiar with the RSS technology. I learned a bit of XML and PHP XML parsing. How does RSS work (e.g. how does the feed reader detect new feeds, etc.), and what are the basic steps in building one (a link to a detailed tutorial would be appreciated too)? I want to integrate a feed into my site blog (that I'm building), and for purposes of learning, I don't want to use Feedburner (unless it is required or extremely neccesary).

Link to comment
Share on other sites

RSS is just a dialect of XML - there is no infrastructure that goes with it. Feed readers simply check the XML file periodically for new content, and display it.To create an RSS file, you just need to read your database and then print out the RSS tags around your content- just like you would do for HTML. There's nothing special about it.

Link to comment
Share on other sites

I didn't realize it was so simple. I just found some code and threw a "feed" together. Very cool. Is there a way of using php or something to find the number of subscribers?

Link to comment
Share on other sites

I didn't realize it was so simple. I just found some code and threw a "feed" together. Very cool. Is there a way of using php or something to find the number of subscribers?
You can check the number of different hosts accessing the feed for one type of measurement - or you can insert special links that indicate an entry from your RSS feed, and count those (e.g. <link>http://my.web.site/article.php?from=rss</link>).
Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...