MultiBlog is a feature in Movable Type that allows content to be easily aggregated from multiple websites or blogs within your Movable Type install to a single website or blog.
While this page title references the MultiBlog template tag, note that it’s many features are detailed here including attributes that can be used with other tags.
It’s likely that you’ll use both the template tags and user interface to configure how MultiBlog functions on your site.
MultiBlog is configured through the Movable Type user interface via the Settings area under the “Tools > Plugins.” MultiBlog can be configured at the System, Website, and Blog levels and settings are inherited. That is, System-level options will be inherited by all Websites and Blogs, and Website-level options will be inherited by Blogs within that Website, for example.
Content Privacy: a way to set default privacy for the selected Website and/or Blogs when not explicitly specifying blog IDs.
MultiBlog Target Default Arguments: Enables use of the MultiBlog tag without the
exclude_blogsattributes. Comma-separated Blog IDs or “all” (for
include_blogsonly) are acceptable values.
Rebuild Triggers: Republish indexes when other blogs change; this is an effective way to keep the aggregating website/blog up-to-date. Note that this feature should be carefully configured — unnecessarily triggering republishing will surely increase server load substantially. Configure the aggregating blog to republish as little as necessary — that is, if Comments are not published on the aggregating blog there is no reason to republish when comments are received.
Click on “Create Rebuild Triggers.” Select a blog, specify the event, and the corresponding action.
The sources can also be configured manually via your template code directly. A number of template tags support the
blog_ids template tag attribute which is used for selecting the blogs across which to aggregate content. For example, the following template tag code sample will aggregate content across blogs with an ID of 1, 2 and 5:
<mt:Entries blog_ids="1,2,5"> <p><mt:EntryTitle></p> </mt:Entries>
If you wish to set a context that includes multiple blogs that can span across multiple tags, one can use the
<mt:Multiblog> template tag. This tag can encapsulate any number of tags that are “multiblog enabled” (see below) and will govern their respective scopes. For example, the following template tag code sample will output the last ten comments and entries for blogs with ids 1, 5 and 8.
<mt:MultiBlog include_blogs="1,5,8"> <mt:Entries lastn="10"> <p><mt:EntryTitle></p> </mt:Entries> <mt:Comments lastn="10"> <p><mt:CommentBody></p> </mt:Entries> </mt:MultiBlog>
If none of these attributes are provided, then Movable Type will default to searching the current blog context only.
ignore_archive_context(New in MT 6.0.2) Usually when a block tag is used in an archive template, any archive filtering conditions that are already in place will be automatically applied (blog ID, category, list of loaded entries, etc.). If the
ignore_archive_contextmodifier is set to
1, data will load without automatically activating preset archive filters.
The following tags support the use of the above attributes. For example:
<mt:Assets include_blogs="1,5,8"> <p><mt:AssetTitle>: <mt:AssetURL></p> </mt:Assets>
Creating a MultiBlog context may not give you the results expected depending upon the combination of tags and attributes used, and the content available in a given blog.
As the previous notes show, the Entries template tag also supports the
blog_ids attribute. But doing:
<mt:MultiBlog include_blogs="3"> <mt:Entries category="foozball"> some yada yada </mt:Entries> </mt:MultiBlog>
is not the same thing as doing:
<mt:Entries blog_ids="3" category="foozball"> some yada yada </mt:Entries>
The second expects that even if the blog with id No 3 does have a category called “foozball,” that very same category must also exist in the current blog.
So if you have this:
- Blog ID 1, categories: foo, bar
- Blog ID 3, categories: foozball, barbarosa
then the second example will fail, because “foozball” isn’t a category in Blog ID 1 where MultiBlog is invoked.