Hi there, I'm very new to Umbraco and in the process of learning how to use Razor correctly and efficiently to pull in content from every blog page under the parent "BlogPages" and display them in a content card on an aggregate blog list.
Each blog page has the field blogHeader, blogHeroImage and blogSummary that I want to pull through to the blog listing page, which condenses a full blog post into a card containing a header and image from the blog post.
I can do this manually from pages using something like this, but this is less than ideal as it requires a specific content node, I want this page to automatically take blogHeader, blogHeroImage and blogSummary from all child pages of "Blog Pages" and display a card for each one, listed chronologically with a maximum of 9 cards shown.
Creating a blog page feed using Razor
Hi there, I'm very new to Umbraco and in the process of learning how to use Razor correctly and efficiently to pull in content from every blog page under the parent "BlogPages" and display them in a content card on an aggregate blog list.
Each blog page has the field
blogHeader
,blogHeroImage
andblogSummary
that I want to pull through to the blog listing page, which condenses a full blog post into a card containing a header and image from the blog post.I can do this manually from pages using something like this, but this is less than ideal as it requires a specific content node, I want this page to automatically take
blogHeader, blogHeroImage and blogSummary
from all child pages of "Blog Pages" and display a card for each one, listed chronologically with a maximum of 9 cards shown.What would be the best way to do this?
Thank you.
is working on a reply...