I have read that someone couldn't get Robert Fosters Sitemap to update with Articulates Blog posts Soooo I did a bit of code because I needed it too.
I added a property called ArticulateID in the sitemap document type which allows me to set an id for the sitemap to pickup that id and include the blog posts as well. I run multiple sites so I just simple add sitemap and articulate to the root and get articulates id and put it in the sitemap property. Pretty easy I think. Anyway Umbraco formatted this code a bit weird so hopefully you'll be able to replicate.
Adding Articulate Blog Posts To Sitemap
I have read that someone couldn't get Robert Fosters Sitemap to update with Articulates Blog posts Soooo I did a bit of code because I needed it too.
I added a property called ArticulateID in the sitemap document type which allows me to set an id for the sitemap to pickup that id and include the blog posts as well. I run multiple sites so I just simple add sitemap and articulate to the root and get articulates id and put it in the sitemap property. Pretty easy I think. Anyway Umbraco formatted this code a bit weird so hopefully you'll be able to replicate.
@using Articulate.Models @using System.Linq @inherits Umbraco.Web.Mvc.UmbracoTemplatePage
@{Layout = null;} @helper ListChildNodes(IPublishedContent startNode) { Response.ContentType = "text/xml"; const int maxLevelForSiteMap = 1000; foreach(var node in startNode.Children .Where(n => n.IsVisible() && n.TemplateId > 0 && !Umbraco.IsProtected(n.Id, n.Path) && (!n.HasProperty("searchEngineSiteMapHide") || !n.GetPropertyValue
@helper ListArticulateNodes() {
} }
is working on a reply...