RSS Feed Reader using Ajax and PHP Part 2
Written By: Jay
- 01 Aug 2006 -
Description: This HOWTO will explain how to extend Building an Ajax & PHP RSS Reader using AjaxAgent Part 1 to include No-Refresh/No-Post-Back Form operations, database interaction as well as auto-complete functions that demonstrate some advanced Ajax/PHP operations. The end result will be an RSS Feed Reader that contains the typical Create, Read, Update and Delete database operations but using Ajax to perform these tasks.
Reading an RSS Feed
Since I covered this in I will not go into detail on reading the RSS Feed.
Set up a DIV to place the RSS Data.
HTML:
id="div_rss">
Include the PHP function rss.
PHP:
include "rss.php";
Create the ajax.
Javascript:
function ReadFeed(str,cat) { agent.call('','rss','ReadFeed_Callback',str,cat); } function ReadFeed_Callback(str) { document.getElementById('div_rss').innerHTML = str; }
Once you've gone through all of that you should be able to add a feed, see a list and select a feed to read.