PDA

View Full Version : RSSBox won't render content



beck.thomson
09-06-2008, 11:46 PM
1) Script Title: RSS Display Boxes

2) Script URL (on DD): http://www.dynamicdrive.com/dynamicindex18/rssdisplaybox/index.htm

3) Describe problem:

I'm trying to use this script to display blog posts from my own blog on the homepage of my site. The blog itself is produced by blogger, but I used FeedBurner to convert the feed, which I assume was successful.

I'm really at a loss here--I've used this script once before, in essentially the same capacity, and it worked fine. Now, it's just not displaying content. There are no error messages, just nothing.

Check out my source here: www.legacystudies.org/testing/index.shtml

ddadmin
09-07-2008, 05:40 PM
When I try to call main.php, it returns a blank page, which is not normal:

http://www.legacystudies.org/testing/rssbox/main.php(blank page)
http://www.legacystudies.org/testing/rssbox/main.php?id=legacy

Make sure the path to your caching directory is correct, with the correct permissions set. If that doesn't help, you may want to try temporarily adding the below line to the top of main.php (right after <?), to turn on PHP error reporting, then call main.php again to see what error message is being returned:


<?
error_reporting(E_ALL);

beck.thomson
09-11-2008, 08:28 PM
Ok, I doublechecked the cache and everything is as it should be.

The addition of the error check to the code returns the indication that something is wrong with the RSS feed, which is what I suspected it might be. The blog is hosted on blogger, and although I subscribed to feedburner to convert the feed, I'm not totally sure that I'm putting it in right.

Here's the section of code in question, from main.php:


<?

error_reporting(E_ALL);
//Function for ouputting the body of each RSS item displayed (inside loop)- DynamicDrive.com

require('../simplepie/simplepie.inc'); //Specify path to simplepie.inc on your server (by default located inside "simplepie" directory)
$feed = new SimplePie();
$feed->cache_location('cache'); //Specify path to cache directory on your server relative to this file
$feed->handle_content_type();
require('outputbody.php'); //Path to custom "outputbody.php" file relative to this file

//Specify list of RSS URLs
$rsslist=array(
"legacy" => "http://feeds.feedburner.com/legacystudies/" //no trailing comma after last RSS URL!!
);

ddadmin
09-13-2008, 02:09 AM
Your main.php code looks fine. However, looking at the source of your page again, there is a problem:


<script type="text/javascript">
//MAIN FUNCTION: rssdisplaybox("rssfeed_id", "rssbox_id", "rssbox_class")
var cssdrivebox=new rssdisplaybox("legacy", "rssbox", "rssclass")
cssdrivebox.set_items_shown(4) //Fetch and display first 4 entries
cssdrivebox.set_template("default") //Use "default" template, which outputs title + description + date
cssdrivebox.start() //Required: start script
</script>

The highlighted parameters are required, yet missing on your page. Not sure if that fixes your original problem above though.