Anders Hattestad
Jan 31, 2011
  5405
(0 votes)

Page structure from pages tagged with a category

With some small modifications of my code of displaying a sub structure of pages on an other page we can now so all pages tagged with one category in the page tree.

This can be used for instance to display a list of front page news items, and one could point to that page to retrieve all pages tagged with that category.

image

The page that are returned are a stub of the orignal page, and uses the fetch data from to retrieve the other properties. The ACL is from the original page.

It seems that you can edit, but the save method doesn't do anything yet.

You add it in the episerver.config like this, and GetPagesTagedWith is either the category name or the ID.

Code Snippet
  1. <pageProvider>
  2.   <providers>
  3.     <add name="FrontPageNews" type="Itera.PageProviders.CategoryPageProvider, EPiServer.Templates.RelatePlus"
  4.            entryPoint="69" GetPagesTagedWith="FrontPageNews"/>
  5.   </providers>
  6. </pageProvider>

 

The code is available here

Jan 31, 2011

Comments

Please login to comment.
Latest blogs
PageCriteriaQueryService builder with Blazor and MudBlazor

This might be a stupid idea but my new years resolution was to do / test more stuff so here goes. This razor component allows users to build and...

Per Nergård (MVP) | Feb 10, 2025

Enhancing Optimizely CMS Multi-Site Architecture with Structured Isolation

The main challenge of building an Optimizely CMS website is to think about its multi site capabilities up front. Making adjustment after the fact c...

David Drouin-Prince | Feb 9, 2025 | Syndicated blog

How to: set access right to folders

Today I stumped upon this question Solution for Handling File Upload Permissions in Episerver CMS 12, and there is a simple solution for that Using...

Quan Mai | Feb 7, 2025 | Syndicated blog

Poking around in the new Visual Builder and the SaaS CMS

Early findings from using a SaaS CMS instance and the new Visual Builder grids.

Johan Kronberg | Feb 7, 2025 | Syndicated blog

Be careful with your (order) notes

This happened a quite ago but only now I have had time to write about it. Once upon a time, I was asked to look into a customer database (in a big...

Quan Mai | Feb 5, 2025 | Syndicated blog

Imagevault download picker

This open source extension enables you to download images as ImageData with ContentReference from the ImageVault picker. It serves as an alternativ...

Luc Gosso (MVP) | Feb 4, 2025 | Syndicated blog