Guide to the New Features of Movable Type 4.2
From Movable Type
This document is a draft document. We are actively seeking feedback and edits from the community before publishing it within our official documentation.
Contents |
Overview
Movable Type 4.2 has a number of new features that can dramatically improve performance for your installation. In addition, it contains a number of key bugs fixes and refinements to Movable Type's templates that you may want to incorporate into your blog and web site.
Therefore, this guide is meant to augment the Community Generated Upgrade Guide and the standard Movable Type upgrade guide and instruct users on what they should be mindful of when upgrading specifically to Movable Type 4.2.
Post Upgrade Tasks
Widget Manager
The Widget Manager plugin has been completely folded into the core application. Therefore it is possible for users upgrading from previous versions for MT 4.2 to conflict with the plugin that will remain behind.
After upgrading users should either:
a) physically remove the Widget Manager plugin by deleting the directory /path/to/cgi-bin/mt/plugins/WidgetManager, or b) disable the Widget Manager plugin from the System > Preferences > Plugins screen.
Making Movable Type Faster
Every user that upgrades to Movable Type 4.2 should see a performance increase without having to make a single change to their templates, plugins or configuration. Users can take advantage of additional performance enhancements by taking special advantage of the following features:
Use Cached Modules and Widgets
Modules and widgets are a type of template that allow other templates to more easily re-use code and HTML that is shared among them. An example of a module/widget is the list of Recent Entries widget which displays the ten most recent entries posted to a blog. Using this as an example you can see how it would be inefficient to fetch from the database the ten most recent entries for every single page on your website. In actuality, you probably only need to fetch that list once, and store it somewhere so that subsequent pages being published have no need to go to the database.
With module caching, this is exactly what happens. For any module or widget on your website you can have Movable Type store its contents for a specified period of time, or until a specific event occurs. This then allows you to instruct Movable Type to only go to the database to fetch the list of then ten most recent entries when a new entry is received -- no matter how many pages are published and republished on your website.
Movable Type gives you a number of options when setting up caching for each module allowing you to fine tune your performance as you see fit.
» Learn more about Module Caching
MORE TO WRITE HERE?
Use Memcached
When using cached modules, if you have memcached enabled then Movable Type will cache template code there as opposed to the database. This will reduce database load even further, which adds additional stability to your system, even if the performance benefits are relatively small.
» How to setup memcached in Movable Type
Use Server Side Includes
Server side includes (SSI) effectively cache modules to the file system. The SSI's content is then included in the page when the page is requested as opposed to when the page is published. This has the benefit of not having to republish your entire site when you want every page to accurately reflect the ten most recently received comments (for example).
In other words, because the contents are written to a file, whenever that file is updated with newer content, every page including that file will automatically be updated. No republishing necessary.
Modularize Your Template Code
Module caching can have a dramatic affect on performance when used strategically. Visit your blog and navigate around looking for aspects of your site that seem repetitive. These sections of your site will most likely benefit you the most by converting into a template module and then turning on module caching. Here are some suggestions for what to look for:
- a list of recent site-wide comments
- a list of recent entries
- a list of categories
- a list of recent assets or uploaded photos
New Configuration Options
Global User Banning
In prior versions of Movable Type users could only be banned on a blog-by-blog basis, and then only if they had left a comment there. That is a perfectly reasonable behavior if Movable Type is being used to manage a network of independent blogs. But what if your Movable Type installation is managing a bunch of related web sites where you may want a user to be banned from all of your blogs at once?
In Movable Type 4.2 we have added the following configuration directive that will instruct Movable Type to treat all of your blogs to behave in many ways like a single blog:
SingleCommunity 1
In order for this configuration directive to operate fully, it is important that all of your blogs are hosted under the same domain. They can belong to different subdomains.
- When an admin bans a user on one blog, that user will be banned across all blogs.
- Movable Type will maintain only a single login cookie for visitors to any of your blogs.
Address Book and Notifications
In Movable Type 4.2, the address book and notifications framework has been deprecated. During you automatic upgrade Movable Type will attempt to retain this feature for you if any entries exist in your address book. However, if you would like to force Movable Type to enable, or disable this feature, the following configuration directive can be added to your `mt-config.cgi` file:
EnableAddressBook 1
Important Template Changes
Comment Threading and Nested Comments
Blog entries have been known to strike impassioned conversations between a myriad of readers. When these readers leave comments they are often replying to the content in other comments.
Comment threading connects these comments with links such that each comment can be linked to the comment it is in reply to, ensuring future readers can more easily follow the conversation and add their construtive thoughts to the discussion.
» Upgrading your templates to include comment threading
Comment Form Updates
Movable Type 4.2 has been significant improvements to how it handles login cookies and commenter sessions. To take advantage of these features and enhancements users are encouraged to upgrade their comment form template and their site's javascript template.
» How to update your comment form template
Search Pagination
Movable Type 4.2 introduced a number of improvements to its search capabilities, including classic paginated search results.
Pagination for Dynamically Published Archives
Movable Type 4.2 introduced the ability to paginate any dynamically published archive template. This document gives an overview of how to turn on pagination for your templates.