Esempio n. 1
0
        public FeedResult GetContentRss(int take, int description, int imageHeight, int imageWidth, string contentType)
        {
            var contents   = ContentRepository.GetContentByType(StoreId, take, true, contentType);
            var categories = CategoryRepository.GetCategoriesByStoreId(StoreId, contentType, true);


            var rssHelper = new RssHelper();
            var feed      = rssHelper.GetContentsRssFeed(MyStore, contents, categories, description, contentType);

            rssHelper.ImageWidth  = imageWidth;
            rssHelper.ImageHeight = imageHeight;

            var comment = new StringBuilder();

            comment.AppendLine("Take=Number of rss item; Default value is 10  ");
            comment.AppendLine("Description=The length of description text.Default value is 300  ");
            return(new FeedResult(feed, comment));
        }