View Full Version : RSS Ticker (Ajax invocation) problem when there is no description to show

09-20-2007, 07:14 PM
1) Script Title: Advanced RSS Ticker (Ajax invocation)

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

3) Describe problem: Problem with no description in RSS feed causing ticker to not initialize.

I have been running the BBC UK football RSS feed (hxxp://newsrss.bbc.co.uk/rss/sportonline_uk_edition/football/rss.xml) fine for about a week. Then it starts to fail, with the error 'Initializing ticker'.

Having talked to my host provider who has investigated, the access to the link is fine. However, there is currently no description for one item in the RSS feed. And I think this must cause the script to not work.

Has anyone else had this problem? I wouldn't have thought that many RSS feeds have a title with no description! Can anyone else get the RSS feed listed above to work / ideas to fix the bug if it is a bug?

Any help much appreciated!



09-21-2007, 09:14 AM
This script does assume that each entry within the feed contains a description element, even if it's blank. Anyhow, try changing the below line:



var dnode=this.feeditems[i].getElementsByTagName("description")
this.description[i]=(dnode.length==1)? dnode[0].firstChild.nodeValue : ""

That should compensate for when an entry has no description element at all.

09-21-2007, 09:28 PM

I've tested the extra code you suggested, and although the other rss feeds work okay still, the BBC feed with no description still doesn't work.

I'm not sure if this means that the script won't work with no description or there is something else wrong somewhere!

Do you have any other ideas?

Thanks for getting back with the mod though! Much appreciated.



09-22-2007, 05:19 AM
Please post a link to the page on your site that contains the problematic script so we can check it out.

09-22-2007, 11:11 AM
Original rssticker.js:

http://www.scor eabet.com/test/rss.htm - 2 feeds - the BBC video sport feed that works, and the BBC sport feed (http://newsrss.bbc.co.uk/rss/sportonline_uk_edition/football/rss.xml) that has no description for 1 of it's news feeds.

http://www.scor eabet.com/test/rss2.htm - Just the 1 feed that doesn't work.

Revised rssticker2.js code (as per prior post)

http://www.scor eabet.com/rss/rss.htm - 2 feeds
http://www.scor eabet.com/rss/rss2.htm - 1 feed that doesn't work

I've tried running just the revised script on my server, just in case it was an issue with the cache directory, but deleting the original script and running the revised script didn't seem to work either.

06-04-2008, 11:39 PM
i have the same problem

here is the feed url