DOM changes to existing <link> elements don't trigger RSS autodiscovery menu updates

NEW
Unassigned

Status

()

Firefox
RSS Discovery and Preview
10 years ago
9 years ago

People

(Reporter: Aubrey Alexander, Unassigned)

Tracking

(Depends on: 1 bug)

Firefox Tracking Flags

(Not tracked)

Details

(Reporter)

Description

10 years ago
User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.6) Gecko/20070725 Firefox/2.0.0.6
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.6) Gecko/20070725 Firefox/2.0.0.6

If you use DOM to dynamically add an RSS link, it does not show up as the new source of the orange RSS icon on the top.  This makes it so dynamic AJAX applications can not offer live RSS feeds of results that can be changed on the fly without page reloading.

Autodiscovery feeds off the DOMLinkAdded event which is
fired when a new link element is added to the DOM, either from the
original parse of the page or from later scripting, so you can create
a new link element with the appropriate attributes, add it to the
document, and have it added to the discovered feeds

Do we need a listener for the companion event,
DOMLinkRemoved, which would remove the previously discovered link?

Reproducible: Always

Steps to Reproduce:
1. Add a link to a URL
2. Use javascript to remove previous, add new
3. Orange RSS icon still points to the old rss feed


Expected Results:  
Orange rss icon should point to the new results
(Reporter)

Updated

10 years ago
Summary: Dynamically DOM updates to not re-discover RSS autodiscovery tags → Dynamically DOM updates do not re-discover RSS autodiscovery tags
(Reporter)

Updated

10 years ago
Summary: Dynamically DOM updates do not re-discover RSS autodiscovery tags → Dynamic DOM updates do not re-discover RSS autodiscovery tags
(Reporter)

Comment 1

10 years ago
What I am trying to do is make an advanced query of a set of data with AJAX-based sliders.  The resultset on the bottom is updated dynamically whenever the sliders are moved.  I'd like a way to use javascript to update the page so the RSS icon can reflect the current search results.   

This kind of interactive functionality is being used more and more as web 2.0 and AJAX are moving to the mainstream.  I think that this is an important step in marrying AJAX with RSS and open the gates to a lot of new, exciting web applications.
(Reporter)

Comment 2

10 years ago
Does anybody have any suggestions on how I could make this work?

Comment 3

10 years ago
bug 380639 seems related.
Depends on: 380639
(Reporter)

Comment 4

10 years ago
Yes, bug 380639 seems to have an attached code with a potential patch for this issue.
Duplicate of this bug: 457409
There's no easy way to fix this without mutation event listeners, which are expensive perf-wise. We could alternatively just rebuild the menu each time it's opened (which would also fix bug 380639), but that might be too slow.
Status: UNCONFIRMED → NEW
Ever confirmed: true
Summary: Dynamic DOM updates do not re-discover RSS autodiscovery tags → DOM changes to existing <link> elements don't trigger RSS autodiscovery menu updates
Well, and whether it's a menubutton or a button depends on the (current) state of the world, and we have a healthy dose of bugs on the way we currently don't show that, so to not block off fixing them the feed list would need to be rebuilt for the tooltip's popupshowing and for click, not just the menu's popupshowing.

Bleah, and it would still block half of showing, since the two things people want are tooltips that say "Subscribe to this page's feed" or "See a list of this page's feeds" and to have a dropmarker when there's more than one. But you might have multiple feeds onload, so we put a dropmarker on the icon, and then all but one is removed, so when you click the icon to see the menu, we grovel through the DOM and decide to remove the dropmarker and load a feed instead of showing the menu you expect.
You need to log in before you can comment on or make changes to this bug.