View Full Version : PHP code for RSS feeds

09-16-2011, 07:13 AM
Hello everyone!!

I am having one doubt that how to program RSS feeds code on my personal website? I have tried many prepared code which is available on Google search engine but still it doesn't work. If anyone have idea about that then please reply me.

Thank you all in advance.

09-16-2011, 11:26 AM
You could get the content from the feed with a php function:

$url = "URL TO RSS FEED";
$content = file_get_contents($url);
$xml = simplexml_load_file($content);

Now you can use $xml as an object with all the data.

09-16-2011, 01:19 PM
Are you trying to "read" RSS ... meaning you want to display someone else's
RSS on your site, or are you trying to "feed RSS" ... creating your own RSS
feed from your website for others to read?


09-16-2011, 01:58 PM
Like i read it now, he means to create a RSS feed

09-16-2011, 02:00 PM
Your answer in post #2 is an RSS "reader", not "feeder".
We both think the OP means "reader".