官术网_书友最值得收藏!

Generating RSS feeds for syndicated items

You can define any number of RSS feeds, and each feed can include any number of syndicated items. Let's check how we can prepare an RSS feed of products.

Getting ready

In the previous recipes, we have already created products under /sitecore/Content/Home/Products/<Product Category>. We will create an RSS feed to list down all the products that we have.

How to do it…

  1. Create an RSS folder under /sitecore/Content/Home. Create an RSS feed item product using the /sitecore/templates/System/Feeds/RSS feed template.
  2. In the field editor pane, fill in valid values in the items, title, and description link fields in the data section. Here, the feed will contain details of all the descendants of the item selected here. You can also use Sitecore query here.

    We have configured the RSS feed and now we have to make the product items available for syndication.

  3. Select standard values of the product template. From the ribbon, select the Design button in the Feeds group in the Presentation tab. It will open the RSS Feed Design dialog, as shown in the following screenshot:
    How to do it…
  4. Select the title, body, and date fields from the drop-down and save the item. The drop-down shows fields of the product template.
  5. Preview the products RSS feed; it will show the RSS feed as shown in the following screenshot:
    How to do it…

There's more…

This is the default behavior of the Sitecore RSS feed. We can also customize the feed behavior by creating a custom feed behavior. Create the custom class and register it in the feed item Type field, as shown in the following image. Learn customizing the RSS feed from http://goo.gl/4OzMfc:

There's more…
主站蜘蛛池模板: 绥化市| 永顺县| 乃东县| 合肥市| 湘乡市| 丰顺县| 葫芦岛市| 南雄市| 辽中县| 勐海县| 休宁县| 彭阳县| 英山县| 陈巴尔虎旗| 佛学| 德兴市| 通州区| 木兰县| 井陉县| 定南县| 山阳县| 岗巴县| 偃师市| 南部县| 潼关县| 顺平县| 吉木乃县| 玉山县| 电白县| 赣榆县| 吉安市| 兴和县| 呼和浩特市| 滦南县| 砚山县| 白水县| 阜城县| 福安市| 龙江县| 文山县| 新密市|