I'm having an issue with this package on a 6.1.6 site.
I have checked the settings against a 4.9.1 site and it's set up in exactly the same way.
So the issue, according the log.txt file is 'umbraco.MacroEngines.DynamicNodeList' does not contain a definition for 'Count' on CultivSearchEngineSitemap.cshtml:line 30
the offending line is:
if (node.Level <= maxLevelForSiteMap && node.ChildrenAsList.Count > 0) { @ListChildNodes(node)
}
If I change this to node.Descendants.Count it works - WORKS in that it doesn't break but the only node that's actually appearing in the sitemap is the sitemap
This is the same if I remove this second check, or if I remove the if statement altogether which I tried for the sake of testing
I Had this problem too and removed the Count check to solve the problem. Incidentally I ended up going back to the xslt version of Cultiv's code as my site was quite large it took about 40 seconds to render the Razor version as opposed to 2 seconds the xslt version takes. Not sure if this is just the fact that this was written pre v6 and I'm using v6.1.3 (similar to you)
Search Engine Sitemap Problems in V6.1.6
Hi guys,
I'm having an issue with this package on a 6.1.6 site.
I have checked the settings against a 4.9.1 site and it's set up in exactly the same way.
So the issue, according the log.txt file is 'umbraco.MacroEngines.DynamicNodeList' does not contain a definition for 'Count' on CultivSearchEngineSitemap.cshtml:line 30
the offending line is:
Incidentally - once in "code mode", how do you break out back into normal paragraph mode?!
I Had this problem too and removed the Count check to solve the problem. Incidentally I ended up going back to the xslt version of Cultiv's code as my site was quite large it took about 40 seconds to render the Razor version as opposed to 2 seconds the xslt version takes. Not sure if this is just the fact that this was written pre v6 and I'm using v6.1.3 (similar to you)
- Tim
I don't think removing the check is an ideal solution but changing the check to node.DescendantsOrSelf.Count seems to work
I tried with node.DescendantsOrSelf.Count, but I only get the first levels below my startnode then..
I have used node.ChildrenAsList.Items.Count > 0 instead, so I get the nodes on lower levels too..
/Bjarne
Same problem here. Changing to node.ChildrenAsList.Count() works as well.
is working on a reply...