Press Ctrl / CMD + C to copy this to your clipboard.
This post will be reported to the moderators as potential spam to be looked at
Topic author was deleted
Say you want to display the latest news on your homepage
And you have this structure
- Home
--Subpage
--NewsArea
----NewsItem
How can you get all newsitems from a razor macro on your homepage?
You should be able to use this, which will return a DynamicNodeList.
Model.Descendants("NewsItem")
Yep, "NewsItem" is a filter on NodeTypeAlias, and it works great, very convenient.
is working on a reply...
This forum is in read-only mode while we transition to the new forum.
You can continue this topic on the new forum by tapping the "Continue discussion" link below.
Continue discussion
Topic author was deleted
Listing all children of a certain doc type
Say you want to display the latest news on your homepage
And you have this structure
- Home
--Subpage
--NewsArea
----NewsItem
How can you get all newsitems from a razor macro on your homepage?
You should be able to use this, which will return a DynamicNodeList.
Model.Descendants("NewsItem")
Yep, "NewsItem" is a filter on NodeTypeAlias, and it works great, very convenient.
is working on a reply...
This forum is in read-only mode while we transition to the new forum.
You can continue this topic on the new forum by tapping the "Continue discussion" link below.
Continue discussion