§The Weblog structure.

Pivot has a versatile weblog structure, which features multiple weblogs, subweblogs and categories.If you want, you can maintain several weblogs with one installation of Pivot at the same time, even sharing or duplicating entries between these weblogs. You can also have multiple subweblogs on one page (most commonly in two or more columns). Pivot comes with one weblog pre-configured, and you can easily add more. If you do not want to have more than one weblog, you can skip to the next section: Changing the Templates.

If, on the other hand, you'd like to know how the Users, Categories, Subweblogs and Weblogs work, read on!

§ About the Categories, Subweblogs and Weblogs Structure.

One of the main features of Pivot is that you can publish multiple weblogs at the same time. You, as a user, do not have to decide on which weblog you want to publish your entries. In fact: You can't, even if you wanted to.

To Illustrate how this works, This section describes an imaginary, but realistic scenario which publishes several weblogs. Each Pivot installation has a number of categories, like 'music', 'movies', or 'linkdump'. The Administrator can select which users can publish in which category. The only thing you, as an author, have to do is select the category in which an item will be published.

Let's make a picture of that, shall we:

Weblog Structure image 1

(larger pic: here)

You see two users here: Bugs and Daffy. Both have authored a few entries, each in one or more categories. (For instance: The entry 'Matrix' is published in the categories 'movies', 'computers' and 'fetishes'). In total there are six categories available, including 'announcements', a category in which neither Bugs nor Daffy are allowed to post entries.

With Pivot you can set up more than one weblog. Each weblog has one or more subweblogs. Each of these subweblogs publishes one or more categories. This might sound complicated, but it is a very flexible and powerful way to maintain more than one weblog at the same time. Continuing our 'Bugs and Daffy'-example, we might have a Pivot install with three weblogs.

In a picture it might look like this:

Weblog Structure image 2

(larger pic: here)

Each subweblog in a weblog publishes one or more categories. Every time the page is published Pivot looks for entries that go into the subweblogs that are part of that weblog.

If we take a closer look at weblog 1 and match that with the entries Bugs and Daffy have written, we can see which entries go into which column, and which entries will not be published in this weblog:

Weblog Structure image 3

(larger pic: here)

Putting these three pictures together, we get an overview of how users, categories, subweblogs and weblogs are interconnected:

internal://808f36a91aae01892c759f3c5e78945e.png

(larger pic: here)

So.. If Bugs should write a new entry in the category 'computers', he doesn't explicitly say on what page the entry gets published. Pivot knows that, because the entry is in 'Music', Pivot needs to republish Weblog 2 and Weblog 3, because those are the weblogs that publish this category.

To summarise all of this: Every user can write entries in one or more categories, and each weblog has one or more subweblogs, and each subweblog publishes one or more categories.

 

§ Using the Weblogs et al.

Now that I've described how the Weblogs, Subweblogs and Categories fit together, it's time to get a little deeper into a real-world example. <!-- For this example we will describe how the AmsterdamCentraal website is set up. Cathelijne used Pivot to build this site that would have lots of different topics and a bunch of different Authors. -->

In Pivot, each different weblog outputs one (and only one) FrontPage. If you did a Fresh Install of Pivot, your FrontPage will be called index.php. This FrontPage has its own template, and on a pristine, vanilla installation of Pivot this is called frontpage_template.html. You can verify this by going to Administration » Weblogs » (your weblog name), and near the bottom of the page you see which templates are used for the Frontpage, the Entry pages and the Archive Pages.

To repeat myself, i'd like you to read this again: Every user can write entries in one or more categories, and each weblog has one or more subweblogs, and each subweblog publishes one or more categories.

Users and Categories

Users and categories are administered in Setting up Users and Setting up Categories. Through these pages you can add users, and set which users are allowed to write entries in which categories.

Weblogs and Subweblogs

If you take a look at your Frontpage template (usually called frontpage_template.html), using the Administration » Edit Templates option. In there, you'll see definitions for two subweblogs. They are marked [[subweblog:standard]] and [[subweblog:linkdump]]. So, in your Frontpage template, you can add subweblogs to your weblog. How they appear in the final, published pages, and what categories they publish, you can set in Administration » Weblogs.

Each subweblog can have a template of it's own to control how it will be displayed. On a standard Pivot we have _sub_entry_standard.html for the standard subweblog, and _sub_entry_linkdump.html for linkdumps. For a new subweblog, you can create new templates, but you can also use existing ones. For more information, read Setting up Weblogs.

Subweblogs and categories

The default install of Pivot comes with two categories. These are called default and linkdump. The default category is published in [[subweblog:standard]] and the linkdump category in, well, [[subweblog:linkdump]]. You can set this in Administration » Weblogs. For these two categories this might seem a bit cumbersome, but as soon as you want to add more categories, you can choose to have one subweblog pulbish more than one category, or have two weblogs that have some overlap in the contenct they publish (because they happen to publish the same categories in their subweblogs)

Tying it all together

§ Examples

Now that you have an idea of what all this weblogs, subweblogs and categories hoopla is about, it's time for some examples to give you some inspiration on how to use them yourselves.

Weblogs

Sometimes you want two weblogs. Maybe you want two categories to appear in two different pages. Or maybe you have a complex layout that doesn't display very well on PDA's or old browsers.

This example has a standard frontpage with too many bells and whistles for simpler browsers: www.hornstra.com/index.php
For those other browsers, there's a minimalist second weblog, in which only the default category is published, nothing more: www.hornstra.com/bare.html. So there's one category (default) that gets published in two weblogs.

Subweblogs

An interesting use of subweblogs can be found on this site: www.amsterdamcentraal.nl. In the right column, you see a list of titles of recent entries. Here's how Cathelijne achieved this:

Categories

Look again at www.amsterdamcentraal.nl. This is a blog about Amsterdam. For each neighborhood in the city, a separate category was created. All of these categories are published in [[weblog:default]](and in [[weblog:title]], as we saw above). So here we have multiple categories published in one subweblog.

What if Cathelijne created a separate log for each of the neighborhoods? If one of the writers publishes an entry this would mean: