I have a script that directs RSS feeds to akregator or amarok. I entered it as a feed reading application in the relevant box. Firefox 3 doesn’t run it at all. This is NOT a script programming issue as the script worked fine until the actual release of Firefox 3 and after some debugging, I’ve ascertained that Firefox doesn’t run it at all. Many people use this script, akadd, and it is available on the web. I gather that non-SUSE users have no problems with the script.
Thanks for all your help. I’ve checked the links, but they haven’t fixed the problem. Here’s the entire function:
addToClientReader: function FRS_addToClientReader(spec, title, subtitle, feedType) {
var prefs = Cc"@mozilla.org/preferences-service;1"].
getService(Ci.nsIPrefBranch);
var handler = safeGetCharPref(getPrefActionForType(feedType), "bookmarks");
if (handler == "ask" || handler == "reader")
handler = safeGetCharPref(getPrefReaderForType(feedType), "bookmarks");
switch (handler) {
case "client":
var clientApp = prefs.getComplexValue(getPrefAppForType(feedType), Ci.nsILocalFile);
// For the benefit of applications that might know how to deal with more
// URLs than just feeds, send feed: URLs in the following format:
//
// http urls: replace scheme with feed, e.g.
// http://foo.com/index.rdf -> feed://foo.com/index.rdf
// other urls: prepend feed: scheme, e.g.
// https://foo.com/index.rdf -> feed:https://foo.com/index.rdf
var ios =
Cc"@mozilla.org/network/io-service;1"].
getService(Ci.nsIIOService);
var feedURI = ios.newURI(spec, null, null);
if (feedURI.schemeIs("http")) {
feedURI.scheme = "feed";
spec = feedURI.spec;
}
else
spec = "feed:" + spec;
var ss =
Cc"@mozilla.org/browser/shell-service;1"].
getService(Ci.nsIShellService);
ss.openApplicationWithURI(clientApp, spec);
break;
default:
// "web" should have been handled elsewhere
LOG("unexpected handler: " + handler);
// fall through
case "bookmarks":
var wm =
Cc"@mozilla.org/appshell/window-mediator;1"].
getService(Ci.nsIWindowMediator);
var topWindow = wm.getMostRecentWindow("navigator:browser");
topWindow.PlacesCommandHook.addLiveBookmark(spec, title, subtitle);
break;
}
Probably there is no problem with this function.
I’m tried to subscribe for rss feed with akregator from mozilla.
First of all, I found this bug: https://bugs.kde.org/show_bug.cgi?id=165160, but the feed is added to akregator.
BTW, why are you using scripts for subscribing - you can directly do that from Firefox.
On any site with RSS feed i click on the RSS icon next to the link. In the Subscribe to this feed using -> I select akregator executable (/usr/bin/akregator) -> Hit Subscribe Now.
OR
Edit -> Preferences -> Applications -> Web Feed (select here akregator, or another application.) - this option will be used as default.
If it isn’t works for you then probably something is wrong with your Firefox, or something is missing.
I recommend you to do a quick search in yast for “mozilla”, and post here the list of installed packages.