繁体   English   中英

Django Feeds / Syndication-函数item_title和item_description不影响显示的内容吗?

[英]Django Feeds/Syndication - The functions item_title and item_description do not effect whats displayed?

我已经定义了一个继承自django.contrib.syndication.feeds.Feed的类

class Rss(Feed):
...
    def item_title(self, item):
       return "Hello"

    def item_description(self, item):
       return "Test"

问题是从方法item_title返回的内容和feed_description不是供稿中使用的内容,即使不使用模板也是如此。

我想念什么吗?

您使用的是最近的中继线结帐,还是版本1.1或更早版本? 自1.1版本发布以来,才引入了item_title等字段。

如果您使用的是1.1,则应参阅1.1文档

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM