Blogs and forums have much to offer in a school setting. They help faculty and students communicate despite large class sizes. They engage students in conversations with each other. And they provide an easy way for instructors and staff members to build their personal reputations—and, thereby, the reputation of your institution. In this article, we consider how best to build blogs and forums in Plone. Along the way, we cite education-domain examples and point out tips for keeping your site stable and your users smiling.
Though Plone wasn’t conceived as a blogging platform, its role as a full-fledged content management system gives it all the functionality of a blog and more. With a few well-placed tweaks, it can present an interface that puts users of other blogging packages right at home while letting you easily maintain ties between your blogs and the rest of your site.
Generally speaking, blog entries are…
Plone provides all of these, with varying degrees of polish, out of the box:
In addition to Plone’s built-in tools, this article will explore the capabilities of several third-party add-ons. Open-source software is often called “free as in beer” or “free as in freedom”. As typical of Plone add-ons, the products we will consider are both. However, they are also “free as in puppies”.
Who can resist puppies? They are heart-meltingly cute and loads of fun, but it’s easy to forget, when their wet little noses are in your face, that they come with responsibility. Likewise, add-ons are free to install and use, but they also bring hidden costs:
These considerations are major drivers of this article’s recommendations. For each of the top three Plone blogging strategies, we’ll outline its capabilities, tick off its pros and cons, and estimate how high-maintenance a puppy it will be. Remember, even though puppies can be some work, a well-chosen and well-trained one becomes a best friend for life.
Using news items as blog entries is, in true Extreme Programming style, “the simplest thing that could possibly work”. Nonetheless, it’s a surprisingly flexible practice and will disappoint only if you need features like pings, trackbacks, and remote editor integration. Here is an example front page of a Plone blog built using only news items, collections, and the built-in portlets:
A blog in Plone can be as simple as a folder full of News Items, further organized into subfolders if necessary. Add a collection showing the most recent News Items to the top-level folder, and set it as its default page. As illustrated below, use an Item Type criterion for the collection to pull in the News Items, and use a Location criterion to exclude those created outside the blog folder:
To provide pagination—recommended once the length of listings starts to noticeably impact download or render timetime—use the Limit Search Results option on the collection. One inconsistency is that only the Summary and Tabular Views on collections support pagination; Standard View (which shows the same information) does not. This means that Summary View, which sports a Read more link and is a bit more familiar to most blog users, is typically a good choice.
Go easy on the pagination
More items displayed per page is better. User tests on prototypes of gap.com’s online store have suggested that, at least when selling shirts, more get sold when all are on one big page. Perhaps it’s because users are faced with a louder mental “Continue or leave?” when they reach the end of a page. Regardless, it’s something to consider when setting page size using a collection’s Number of Items setting; you may want to try several different numbers and see how it affects the frequency with which your listing pages show up as “exit pages” in a web analytics package like AWStats.
As a starting point, 50 is a sane choice, assuming your listings show only the title and description of each entry (as the built-in views do). The ideal number will be a trade-off between tempting visitors to leave with page breaks and keeping load and render times tolerable.
Finally, make sure to sort the entries by publication date. Set this up on the front-page collection’s Criteria tab by selecting Effective Date and reversing the display order:
As with all solutions in this article, a blog built on raw News Items can easily handle either single- or multi-author scenarios; just assign rights appropriately on the Sharing tab of the blog folder.
Unadorned News Items are a great way to get started fast and confer practically zero upgrade risk, since they are maintained as part of Plone itself. However, be aware of these pointy edges you might bang into when using them as blog entries:
The great thing about plain News Items is that there’s a forward migration path. QuillsEnabled, which we’ll explore later, can be layered atop an existing news-item-based blog with no migrations necessary and removed again if you decide to go back. Thus, a good strategy may be to start simple, with plain news items, and go after more features (and risk) as the need presents itself.
One step up from plain News Items is Scrawl, a minimalist blog product that adds only two things:
Scrawl’s Blog Entry isn’t quite a verbatim copy of News Item; Scrawl makes a few tweaks:
Calm your ringing phone by cloning types
Using a custom content type for blog entries—even if it’s just a copy of an existing one—has considerable advantages. For one, you can match contributors’ vocabulary: assuming contributors think of part of your site as a blog (which they probably will if the word “blog” appears anywhere onscreen), they won’t find it obvious to add “news items” there. Adding a “blog entry,” on the other hand, lines up naturally with their expectations. This little trick, combined with judicious use of the Add new… → Restrictions… feature to pare down their options, will save hours of your time in training and support calls.
A second advantage of a custom type is that it shows separately in Plone’s advanced search. Visitors, like contributors, will identify better with the “blog entry” nomenclature. Plus, sometimes it’s just plain handy to limit searches to only blogs.
This type-cloning technique isn’t limited to blog entries; you can clone and rename any content type: just visit portal_types in the ZMI, copy and paste a type, rename it, and edit its Title and Description fields. One commonly cloned type is File. Many contributors, even experts in noncomputer domains, aren’t familiar with the word file. Cloning it to create PDF File, Word Document, and so on can go a long way toward making them comfortable using Plone.
Scrawl’s biggest risk is lock-in: since it uses its own Blog Entry content type to store your entries, uninstalling it leaves them inaccessible. However, because the Blog Entry type is really just the News Item type, a migration script is easy to write:
# Turn all Blog Entries in a Plone site into News Items.
#
# Run by adding a “Script (Python)” in the ZMI (it doesn’t matter
where) and pasting this in.
from Products.CMFCore.utils import getToolByName
portal_catalog = getToolByName(context, ‘portal_catalog’)
for brain in portal_catalog(portal_type=’Blog Entry’):
blog_entry = brain.getObject() # Get the actual blog entry from
# the catalog entry.
blog_entry.portal_type = ‘News Item’
# Update the catalog so searches see the new info:
blog_entry.reindexObject()
The reverse is also true: if you begin by using raw News Items and decide to switch to Scrawl, you’ll need the reverse of the above script—just swap ‘News Item’ and ‘Blog Entry’. If you have news items that shouldn’t be converted to blog entries, your catalog query will have to be more specific, perhaps adding a path keyword argument, as in portal_catalog(portal_type=’News Item’, path=’/my-plonesite/ blog-folder’).
Aside from that, Scrawl is pretty risk-free. Its simplicity makes it unlikely to accumulate showstopping bugs or to break in future versions of Plone, and, if it does, you can always migrate back to news items or, if you have some programming skill, maintain it yourself—it’s only 1,000 lines of code.
I remember deciding to pursue my first IT certification, the CompTIA A+. I had signed…
Key takeaways The transformer architecture has proved to be revolutionary in outperforming the classical RNN…
Once we learn how to deploy an Ubuntu server, how to manage users, and how…
Key-takeaways: Clean code isn’t just a nice thing to have or a luxury in software projects; it's a necessity. If we…
While developing a web application, or setting dynamic pages and meta tags we need to deal with…
Software architecture is one of the most discussed topics in the software industry today, and…