Firefox 2.0发布后,用户抱怨最大的似乎对Feed的显示不使用用户定义的XSL和CSS(Feedsky的吕欣欣同学曾经抱怨过,昨天看到Zola也抱怨了)。这个问题已经被提交为Firefox的一个Bug,但是Firefox开发团队认为这是个功能而不是Bug,不用修改(WONTFIX)。
Ben Goodger, 年轻的Firefox开发者,昨天做了自己的解释:
In general, we felt that RSS reader was a very personal choice to be made by the user, and that we did not want to compete with existing RSS readers that exist, which are very competent in a variety of ways. Rather, we wanted to allow users to easily subscribe to feeds using their favorite reader. The UI presented is not intended to be one for consuming the content, but rather previewing the content before subscription (since many feeds have non-descriptive titles). I think this is where the confusion arises, because the presentation is similar to Safari’s and IEs and so people may expect reading functionality.
Firefox在看到一个URL的页面是XML后,会先扫描(scan/sniff)文档的前512个字节,如果发现有<rss或者<feed,就判断这是个feed文档,不理会自带的style,而直接使用Firefox的方式展现这个文档。所以,最快速和简单的解办法就是不让Firefox在文档的前512字节里看到<rss和<feed。上述的Bug报告的反馈里,Firefox开发者就提到了这个Hack:
The emerging workaround for this problem (which isn’t new to us, since we’re using the same heuristic that IE7 betas have been using for months) is to put in a comment ranting about the evils of sniffing web content and overriding the desires of web developers which is long enough to move "<rss" or "<feed" out of the first 512 bytes, since that’s all we sniff.
这是最简单的办法,代价是512字节。Mozilla Developer Center也提出了另外两个方法,见Custom styles for RSS。
中午向Zola建议了这个办法,充满PK精神的Zola小朋友于是在自己的feed文档的开头部分加进了了三十二遍“f*** firefox2.0”的xml comment后,Firefox2.0上成功显示了用他自己定义的风格的feed。
我个人看法是Firefox应该尊重信息发布者以及阅读者自己的选择,在没有自定义的时候使用Firefox的显示方式,在已有定义风格的时候,还是尊重发布者,使用他们定义的风格。
话又说回来,我还是不很理解为什么要对Feed定义显示风格,Feed是给机器/程序读取最近更新内容,用来展现内容的毕竟还是HTML。 (http://www.yining.org/)
Firefox2.0下载


