« New Feature: Allow side blocks to contain inline @formulas | Main| New Feature: Transparent support for better image resizing via "Import Image 2 Lotus Notes" (II2LN) »

New Feature: Category Header Static Page

Tags: New Features Static Page

One of the things I really like about Blogsphere is its nice ability to tag the blog entries and then later show all the blog-entries within that tag. If I for example write a blog-entry with the tag "New Features", I can easily see all the entries within the "New Features"-topic. However, I thought it would be nice to have a type of category header  on top of all blog entries. It look like this;

A picture named M2

Note how the red rectangle shows the static Category Header page, followed by the ordinary blog-entries within the "New Features" category.
Also note that the static page doesn't show the footer-part, and this is controlled by the new "Category Header"-part of the page templates's Document definitions;

A picture named M2

Now, how do the code know when to display a Category Header or not? Simply by having a static page with a specially prepped permalink code!

If you want a Category Head, simply assign the "cathead: " + the category code as the permalink;

A picture named M3

I know that the Category Head could/should probably be a separate type of page, and as so don't interfere with the ordinary static pages.

However, the current implementation has very simple and effective plug-in logic and doesn't mess up the existing code too much

This feature is implemented by adding the RenderCategoryHeaderStaticPage to the script library RenderEngine.Blog. It looks like this;

A picture named M4

And this function is called from the RenderEngineArchiveList  function, like this;

A picture named M5

This makes the RenderEngineAcrhiveList first check whether we have a static page with the permalink code equal to "cathead: " + currenttag, and thus render that static page first, before the ordinary blog entries.

You can see this feature in play if you click on the New Features in the tag cloud!

Calendar

Search Site

Tag Cloud

Domino BlogSphere
Version 3.0.2

A Code Snippit

The Home URL of this db is http://dev.blogsphere.net/blogsphere/bsphere3.nsf