404
error page that comes with MT
Movable Type (http://www.movabletype.org/) is a web-based personal publishing system. It is designed to ease maintenance of regularly-updated news or journal sites, like weblogs. It contains features common to many other such systems (hosted locally on your server, template-driven, highly-configurable, permalinks, etc.); in addition, it also includes support for the following features:
Hold
, then let an editor approve by marking Release
, at which
point the entries will be published on your site.
Movable Type is Copyright 2001, 2002 Mena G. Trott and Benjamin Trott. All rights reserved.
Please see the document mtinstall.html for information on installing Movable Type.
The Movable Type system supports multiple blogs. A blog is simply a collection of entries, templates, and everything else you see on the blog Editing Menu.
You can create a new blog (if you have blog-creation privileges, that is)
by logging in to Movable Type, then clicking Create New Blog
. Fill in
the configuration information, then press SAVE
; you will automatically
be assigned full permissions for this new blog.
You can edit the configuration of an existing blog by logging in to Movable
Type, selecting the blog you wish to configure from Your existing blogs
,
then clicking Edit Blog Configuration
.
When creating a new blog, you will need to perform the following steps:
Setting up your
Blog Directories
.
Main Menu
, click Create New Blog
; then configure your blog in
the standard blog configuration screen. When you are done with your blog
configuration, press SAVE
.
Don't rebuild yet; wait until you've posted your first entry (in Step 4).
List & Edit Templates
screen, if
you'd like.
Movable Type supports many options for configuring the way your blog works.
These options can be set on the Edit Blog Configuration
screen, where each
option is explained briefly. Some options require more explanation, however:
file(s)
will be located. An
absolute path (a path starting with /
) is preferred, because it is not
dependent on the location of your Movable Type directory; but if you choose to
use a relative path, the path should be relative to your Movable Type
directory.
This is a required field.
Example: /home/melody/public_html/blog
http://
and your site's domain name) to your public
weblog. This URL should not include the filename of your index file; for
example, if your index file is located at
http://www.your-site.com/blog/index.html, then the value for Site URL
should be http://www.your-site.com/blog/.
This is a required field.
Example: http://www.your-site.com/blog/
This is a required field.
MTEntries
tag; this is merely the
default, used when you do not supply MTEntries
with any attributes.
For example, if you wish to display the last 15
entries that you have
posted to your blog, you could use the lastn
attribute to MTEntries
instead of relying on the default behavior:
<MTEntries lastn="15"> ... </MTEntries>
Note also that, if you choose 7
days, 7 days means the last 7 consecutive
days, not necessarily the last 7 days on which you posted an entry. So if
you have posted on just 3 of the last 7 days, only the posts from those 3 days
will be listed on your main indexes.
This is a required field.
N
words of your entry.
The number of words in the excerpt defaults to 20
.
If you would like Movable Type to notify weblogs.com of updates to your site automatically, whenever you post a new entry (or save an existing entry), check this box.
If unchecked, weblogs.com will not be notified of updates to your blog.
Recently
updated key
. This key will then be sent to movabletype.org whenever you update
your site, and your site will be marked as recently updated.
/
) is preferred, because it is not dependent on
the location of your Movable Type directory; but if you choose to use a
relative path, the path should be relative to your Movable Type directory.
Note that, if you wish to place your archive files in the same directory as
your index files, the Local Archive Path
and the Local Site Path
should
point to the same directory.
This is a required field.
Example: /home/melody/public_html/blog/archives
http://
and your site's domain name) to the archives
section of your public weblog.
This is a required field.
You do not have to select any archive types, if you don't want archiving on your blog; just leave all of the boxes unchecked.
Archive Type
that you use, you can
define an Archive File Template
in the box to its right on the
configuration screen.
For example, by default monthly archive files are stored directly in your
Local Archive Path
, and are called YYYY_MM.html (2001_12.html, for
example). You might prefer your monthly archives to be stored in
2001/12/index.html. To do this, you can set the Archive File Template
for your Monthly
archives to
<$MTArchiveDate format="%Y/%m/index.html"$>
Another example: by default individual archive files are named by the padded
form of the entry ID (000002.html, for example), and are stored directly
in your Local Archive Path
directory. You may wish to impose a hierarchy
on your archives, based on the category into which you've placed them; for
example, you would place all entries in the category Books
into a
directory called books/. To do this, you can use the following Archive
File Template
for your Individual
archives:
<$MTEntryCategory dirify="1"$>/<$MTEntryID pad="1"$>.html
Archive File Templates
are defined using a subset of the standard Movable
Type template tags. The following tags can be used in
Archive File Templates
:
<$MTArchiveDate$>
(doc) for date-based archives
(Monthly
, Daily
, Weekly
)
<$MTArchiveCategory$>
(doc) for Category
archives
<$MTEntry*$>
(doc) tags
for Individual
archives
NOTE: when using Archive File Templates
, you must append the file
extension that you wish to use for your archive files (as in the examples
above). The file extension that you specify in File extension for archive
files
will not be used.
If you have not selected any archive types (Archive Frequency
, above), you
should select No Archives
for your Preferred Archive Type
.
Entries form the basis of your blog; they are the content, whereas the
templates (below) generally define how that content appears. You can create
a new entry by logging in to Movable Type, selecting a blog, then clicking
Create New Entry
. You can edit your existing entries by clicking List
& Edit Entries
, then selecting an entry from that list.
When creating a new entry, you will have the chance to set the following fields:
MTEntryExcerpt
tag) by selecting the first twenty (20) words from your
entry, followed by an ellipsis.
More
text and enter only
the Blog Entry
text. Movable Type allows you to split up your entry for
more flexibility in the display of that entry; for example, if you write very
long entries, you may not want your entire entry on your index pages. You
can use the two fields to control what gets displayed, and where.
Note that when the text of your entry and extended entry fields are outputted
into your public blog, paragraphs--blocks of text separated by two line
breaks--will be automatically enclosed within <p> and </p>
tags. If you do not want this transformation to occur, uncheck the Convert
paragraph breaks
option in the Edit blog configuration
screen.
Status
set to Hold
will not be published to your blog.
MTEntryIfAllowComments
area will be displayed (see TEMPLATE TAGS, below).
You can use the PREVIEW
button to preview your entry before posting;
CANCEL
will return you to the List Entries page.
After you have saved a new entry, you will be transferred directly into editing mode for that entry. When editing an existing entry, you will have several new options:
Authored on
date and time for an entry. If you change this value, you
must use the form YYYY-MM-DD HH:MM:SS
; otherwise you will get an error.
DELETE ENTRY
; you will then be
asked to confirm that you really wish to delete the entry. Agree, and your
entry will be deleted.
Note that, upon saving an entry that is marked for Release
, your archives
for that entry, along with all of your indexes, are automatically rebuilt.
Thus you do not need to manually rebuild your files (see REBUILDING FILES,
below) after posting a new entry, or after editing an existing entry.
If you are using Movable Type on Internet Explorer for Windows, you can make use of a couple of keyboard shortcuts while editing your entries, to automatically insert HTML formatting tags. To use these shortcuts, select the text you wish to format in your entry, then press the appropriate keyboard shortcut combination:
You can use Movable Type's search and replace functionality either to search through all of your entries for a particular string, or to replace all instances of a string with another string. IMPORTANT: there is no undo feature, so be careful when you use the replace functionality; because of this you may want to export your Movable Type entries before using replace, for backup purposes.
You have the following options when using search and replace:
Case Sensitive
box. This means that the string foo
will match
foo
, Foo
, fOo
, etc.
Regular Expression Match
. If you are unsure what this means, you
would do best to leave this box unchecked.
Title
, Entry Body
, and
Extended Entry Body
fields of each entry in your blog. You can tune the
search and replace to operate on only a subset of these fields by checking and
unchecking the Search fields
boxes.
Movable Type supports many archiving options: you can archive by date (daily, weekly, or monthly), by category, or by individual entry. This last option means that each entry will be placed on its own page. Each blog can use multiple archive frequencies and types; for example, your blog could use Daily, Monthly, and Category archiving. Archive types are selected in the Edit Blog Configuration screen, or can be chosen when creating a new blog. Be aware, however, that the more archive options you choose for a particular blog, the longer it will take to rebuild your files (Rebuild).
If you do select multiple archive options, you must select a preferred archive type. The preferred archive type is used when constructing links to your entries--for permalinks, for example. A link can only point to one possible archive type; to set this type, set your Preferred Archive Type in the Edit Blog Configuration screen.
You will need to create templates for each of your archive types. See TEMPLATES, below, for information on which templates apply to which archive types.
No matter what type of archiving you use, you will likely wish to create a
master list of all of your archives. In Movable Type, a master archive index
is just a regular index template; however, instead of using the MTEntries
tag--as you do with most other index templates--you instead use the
MTArchiveList
tag. This tag, and associated tags for use with creating a
master archive index, are described in TEMPLATE TAGS, in the Master
Archive Index section.
Movable Type features a built-in comment system. You can edit existing
comments for a particular entry by selecting that entry for editing, then
looking in the Edit Comments area. Comments will be listed there; you can
edit a comment by clicking on the name of the author, then editing the comment
on the resulting page. You can delete comments by checking their checkboxes,
then clicking DELETE CHECKED
.
The default templates that ship with Movable Type are comment-ready; in other words, you should be able to use comments in your blog without editing any of the comment templates at all. The default templates are set up so that comments appear on both the popup comment window (linked from the Main Index template) and the individual archive pages. You can alter this behavior by altering the appropriate templates.
Movable Type's comment system can be used in either of two ways (or both):
<p><font class="title"><$MTEntryTitle$></font></p> <$MTEntryBody$>
<MTComments> <$MTCommentBody$> <font class="post">Posted by <$MTCommentAuthorLink$>.</font><br><br> </MTComments>
In fact, the default Individual Entry Archive Template contains this same structure.
<MTComments> <$MTCommentBody$> <font class="post">Posted by <$MTCommentAuthorLink$>.</font><br><br> </MTComments>
The following Javascript function is used to link to the comment popup window:
<script language="javascript"> function OpenComments (c) { window.open('<$MTCGIPath$>mt-comments.cgi?' + 'entry_id=' + c, 'comments', 'width=480,height=480,scrollbars=yes,status=yes'); } </script>
And the following code invokes the Javascript function:
<MTEntryIfAllowComments> <a href="#" onClick="OpenComments(<$MTEntryID$>)">Comments</a> </MTEntryIfAllowComments>
Of course, in either of these scenarios, you will also want to provide a form for users to enter new comments. That form can look something like this:
<form method="post" action="<$MTCGIPath$>mt-comments.cgi"> <input type="hidden" name="entry_id" value="<$MTEntryID$>">
Name: <input name="author"><p> Email Address: <input name="email"><p> URL: <input name="url"><p> Body: <textarea name="text" rows="10" cols="50"></textarea><p>
<input type="submit" name="preview" value="PREVIEW"> <input type="submit" name="post" value="POST"> </form>
If you are using static/inline comments, note that the sample form above will require the addition of one more hidden input field:
<input type="hidden" name="static" value="1">
This tells the comments system that you are using inline comments, which will force a rebuild of the entry archives and of the index pages for your blog, after a new comment is posted.
Note that in either scenario--inline comments or popup comments--your index
pages will be rebuilt after a new comment is added; this is to update the
count of the number of comments on the entry (see the MTEntryCommentCount
tag, in TEMPLATE TAGS, below). In addition, if you are using inline
comments, your archive pages for the entry will be rebuilt; this is to add
the new comment to your individual entry archive page for the entry.
Comment previews are built into Movable Type, so that your visitors can
preview their comments before posting. Support for previews ships with the
default templates built into the system; you can remove this support, if you
wish, by removing the PREVIEW
button from the comments form. The layout of
the comment previews is defined using the Comment Preview
template. You
can use the <$MTCommentPreview*$>
tags, along with the global tag
attribute encode_html
, to create an editable comment preview form; this
allows users to preview their comment, then edit the comment being previewed,
then post the comment. The default templates have an example of an editable
comment preview template.
When creating an editable comment preview template, you should always paste
this hidden input field into the forms in your Comment Preview
and
Comment Error
templates:
<input type="hidden" name="static" value="<$MTCommentPreviewIsStatic$>">
This is a magical tag that tells the system whether a user is posting a comment from your individual archives, or from the comment popup window, so that the user can be redirected to the proper page after posting a comment.
You can also list all of the previous comments posted to the entry, using the standard <MTComments> container tag:
Previous comments: <MTComments> <$MTCommentBody$> Posted by <$MTCommentAuthorLink$> at <$MTCommentDate$> </MTComments>
If an error occurs when a comment is submitted--for example, if you have
disallowed anonymous comments, and the user does not supply a name or email
address--you can customize the error page that the user receives using the
Comment Error Template
. You can use this template to provide a form where
users can fix whatever error has occurred in their submissions, then re-post
(or preview) the comment. The default templates have an example of a
Comment Error Template
( http://www.movabletype.org/default-templates.html ).
Templates in the Movable Type system are your method of defining the design and layout of your site. Templates describe where you want your content (that is, your entries and archives), what that content should look like, and so on. Generally your templates will be made up of HTML, interspersed with Movable Type template tags and variables (see TEMPLATE TAGS, below), but this is not a technical limitation; you can use Movable Type to generate plain text, HTML with server-side includes, PHP, and any other text-based language.
You can edit your blog's templates, and define new templates, by logging in to Movable Type, selecting a blog, then clicking List & Edit Templates.
There are several different types of templates in Movable Type.
Index templates are your main entry listings. Unlike many other weblog
management systems, Movable Type supports multiple index templates; this means
that you can publish your main entry listings in several formats, for
example, like one listing in HTML, and one in XML. By default, an index
template displays the last N
days worth of entries, where N
is defined
in your blog configuration. For example, if you set the number of days
displayed on the index to 7
, Movable Type will, by default, display all
entries from the last 7 days on all of your index templates. Note that 7 days
means the last 7 consecutive days, not necessarily the last 7 days on
which you posted an entry. So if you have posted on just 3 of the last 7 days,
only the posts from those 3 days will be listed on your main indexes.
As mentioned above, displaying the last N
days of entries is the default
behavior for index templates; this behavior is customizable, however, through
the MTEntries
tag (see below); for example, you might set your RSS index
(for RSS syndication) to display your last 15 entries, no matter the date.
Archive templates define the look and feel or your blog archives. Since Movable Type allows for several different types of archiving (see Archiving, above), there are several equivalent types of archive templates:
Movable Type allows you to extract common chunks of HTML code into templates
that you can then include in your other templates; in Movable Type, these
common templates are called Template Modules
. An example of the use for
such a template might be a header that you use throughout your site. You
can create a new template module called Header
, paste in the common header
code, then save the new template. You can then include this code in all of
your other templates using the MTInclude
tag:
<$MTInclude module="Header"$>
This tag will be replaced by the contents of the Header
custom template.
This allows you to keep all common code in one place, so that if you need to modify it, you only need to modify it in one place.
These are the templates that don't fit as Index Templates, Archive Templates, or Custom Templates. Currently, the templates in this category are:
Uploaded Image
Popup Template
, an HTML file will automatically created that to contain the
image in a popup window. There are three template tags that you can use in
this template: <$MTImageURL$>
, <$MTImageWidth$>
, and
<$MTImageHeight$>
.
After selecting a template to edit in the List & Edit Templates
screen--either by clicking on the name of an index template or a template
module, or by clicking the EDIT
button for the archive or miscellaneous
templates--you will be presented with the Edit Template
screen. Depending
on the type of template you are editing, or whether you are editing a template
module, the template-editing screen will differ slightly in appearance. For
example, only on an Index Template
will you be able to assign an Output
file
.
Here are the fields you may be presented with on the Edit Template
screen:
List & Edit Templates
screen. In addition, when including a
template module using <MTInclude>
, you will need to specify the
name of the template module to include; that name will be the name that you
enter here.
The template name is editable only for index templates and template modules; it is assigned automatically for archive and miscellaneous templates.
The output file applies only to index templates.
The value of the linked filename should be either a full path on the
filesystem to your external file, or a path relative to the Local Site Path
for your blog. For example, if you would like to maintain your Main Index
template through an external editor, you might set the linked file to
index.html.tmpl. You can then edit this file externally and save it to your
webserver; when you rebuild, Movable Type will grab the latest version of the
linked file index.html.tmpl and use that as the template (it will also
update the copy of the template in the Movable Type database, so that the next
time it needs the template, it can use the version in the database).
NOTE: when you create a new template without specifying a template body, and link it to a file that already exists, the contents of that file will be pulled in to the template. If you do specify a template body, however, and the linked file already exists, that linked file will be overwritten with the template body you specified.
Linking a template to an external file is optional; you are free to maintain all of your templates through the Movable Type application itself, if you wish.
Movable Type ships with a set of default templates that are customizable through stylesheets; the same template markup can be made to look completely different by inserting a new stylesheet. You can view the default templates themselves at http://www.movabletype.org/default-templates.html .
To select a new style for your blog, follow these instructions:
List & Edit Templates
.
Stylesheet
;
open this template for editing.
Template body
box of the template you opened for editing in Step 2.
SAVE
button to save the new stylesheet.
REBUILD
link, select
Rebuild Indexes Only
from the pulldown menu, and click the REBUILD
button.
NOTE: some browsers (Internet Explorer for Windows, for one) refuse to reload a stylesheet from the webserver once they have fetched it once; if, when you view your site, nothing has changed, you should empty your browser cache and try again.
Movable Type templates are composed of special tags embedded within standard chunks of plain text (or HTML, as the case may be). Certain tags are ``container'' tags: they contain what might be called a subtemplate, a chunk of text and MT tags between two other MT tags. Typically a container tag represents either a loop or a conditional.
Non-container tags are simple variable tags: they are placeholders for dynamic pieces of information.
All Movable Type tags are enclosed within less-than greater-than signs,
just like HTML tags. You can optionally insert a $
inside these signs,
like this:
<$MTEntryBody$>
This can be useful to quickly determine whether a particular tag is an HTML tag or a Movable Type tag.
Movable Type tags take attributes to modify their behavior. Tag attributes
work similarly to HTML tag attributes: they are lists of name="value"
pairs,
separated by spaces. For example:
<MTEntries author="Foo" category="Bar">
(Look at the MTEntries
documentation to determine what this does.)
Attribute values must be enclosed in quotes; otherwise they will not be
parsed correctly. When using attributes in a tag where you are using the
$
character after the start and before the end tags, you should place the
attributes before the end $
character. For example:
<$MTEntryDate format="%B %e, %Y"$>
Some tag attributes are global; they apply to all Movable Type variable substitution tags. Global attributes are discussed below in Global Tag Attributes. Other attributes are tag-specific; they apply only to certain tags. These attributes are listed along with the tags that they apply to, below.
Some Movable Type tags are context-sensitive. For example, it only makes
sense to use an MTComments
tag in the context of a particular entry:
for example, in a Comments Popup
template, or in an archive template
designed for use with Individual
entry archives.
Site URL
(in the Blog Configuration screen) were
http://www.your-site.com/blog/, the hostname piece would be
www.your-site.com
.
N
days of entries, where
N
is the number of days you have set in your configuration for this
particular blog. To alter this behavior, you can provide one of the
following attributes:
N
posts to this blog, where N
is some number greater
than 0.
category name
. Note that this can be a
long list of entries, and you may want to use lastn
to only display a
certain number of entries.
author name
. Note that this can be a long
list of entries, and you may want to use lastn
to only display a certain
number of entries.
N
days old.
NOTE: you can combine lastn
, category
, and author
to filter the
list of entries (days
, however, should be used by itself; if it is used
with any other attribute, the other attribute will override it). For example,
you can supply both lastn
and category
to MTEntries
; doing this does
just what you would expect: it displays the last N entries in a particular
category. If you wished to filter that further, by author name, you could
supply all three of lastn
, category
, and author
:
<MTEntries category="Fun" author="Me" lastn="10"> ... </MTEntries>
This would display the last 10 entries by author Me
in the category Fun
.
...
)
will be used, instead.
If you have provided an excerpt for the entry, note that line and paragraph
breaks will not be converted unless you use the convert_breaks
attribute to
this tag:
Excerpt with line breaks converted: <$MTEntryExcerpt convert_breaks="1"$>
Convert line and paragraph
breaks
in your blog configuration, paragraphs--blocks of text separated by
two line breaks--will be enclosed within <p> and </p> tags,
and for each single line breaks, a <br /> tag will be inserted.
Note that you can override the global Convert line and paragraph breaks
setting by providing this tag with the convert_breaks
attribute; if this
attribute is present, it always overrides the global setting. So, for example,
if you have the global setting turned on, but wish to turn it off for a
specific instance of this tag, you can do so like this:
<$MTEntryBody convert_breaks="0"$>
Convert
line and paragraph breaks
in your blog configuration, paragraphs--blocks of
text separated by two line breaks--will be enclosed within <p> and
</p> tags, and for each single line breaks, a <br /> tag will
be inserted.
Note that you can override the global Convert line and paragraph breaks
setting by providing this tag with the convert_breaks
attribute; if this
attribute is present, it always overrides the global setting. So, for example,
if you have the global setting turned on, but wish to turn it off for a
specific instance of this tag, you can do so like this:
<$MTEntryMore convert_breaks="0"$>
Preferred Archive Type
. This is the default behavior; to
override it you can provide this tag with the attribute archive_type
,
setting it to the archive type you wish to link to.
For example, say that you have selected Individual
archiving as your
Preferred Archive Type
. The following tag:
<$MTEntryLink$>
would produce a link to the individual entry archive page for this entry. That
file name would be the ID of the entry, zero-padded to 6 digits, followed by
your blog's Archive File Extension
(eg. html
).
If you had also enabled By Category
archiving for this blog, though, you
might wish to link instead to the category archive for a particular entry. To
do this, you could use this tag:
<$MTEntryLink archive_type="Category"$>
This tag would be substituted by a link to the category archive page for this entry.
If you want true permalinks--that is, links that will always link to a
particular entry, even when it is archived on a page with several other
entries--you will likely need to include an anchor (#
) in your link. You
can generate true permalinks by combining the MTEntryLink
and MTEntryID
tags, like this:
<a href="<$MTEntryLink$>#<$MTEntryID pad="1"$>">Link</a>
The pad=``1'' tells Movable Type to zero-pad the entry ID to six (6) digits.
See MTEntryID
, below.
format
attribute. See Date Tag Formats for more information.
<MTEntryIfExtended> <a href="<$MTEntryLink$>#<$MTEntryID$>">More...</a> </MTEntryIfExtended>
Allow comments
setting is turned on in the Edit an entry
screen for this entry).
You can use this to display a link to comments on this entry, but only
(of course) if comments are allowed.
See the Comments section in ENTRIES (above) for examples of using this tag.
8
, this tag will produce
only the value 8
. Sometimes you would rather have your IDs padded; in
that case, you can use the pad attribute to the MTEntryID
tag:
<$MTEntryID pad="1"$>
This will zero-pad the entry ID to six (6) digits, like 000008
.
MTEntryPrevious
context, for
example, an <$MTEntryTitle$> tag refers to the title of the previous
entry. After you end this context (with a </MTEntryPrevious> tag),
tags return to referring to the current entry.
See the documentation for MTEntryNext
(below) for an example of usage of
this tag.
MTEntryNext
context, for
example, an <$MTEntryTitle$> tag refers to the title of the next
entry. After you end this context (with a </MTEntryNext> tag), tags
return to referring to the current entry.
Here is an example of navigation that links to the previous and next entries, along with a link back to the main index for your blog.
<MTEntryPrevious> <a href="<$MTEntryLink$>"><< <$MTEntryTitle$></a> | </MTEntryPrevious> <a href="<$MTBlogURL$>">Main</a> <MTEntryNext> | <a href="<$MTEntryLink$>"><$MTEntryTitle$> >></a> </MTEntryNext>
MTEntries
container. For example:
<MTEntries> <MTDateHeader> <$MTEntryDate format="%B %e, %Y"$> </MTDateHeader> Title: <$MTEntryTitle$> </MTEntries>
MTDateHeader
tag to wrap all of
your posts from a particular day in some sort of structure (a div
, for
example). Like MTDateHeader
, this tag is only useful inside an MTEntries
container. For example:
<MTEntries> <MTDateHeader> <div class="day"> <$MTEntryDate format="%B %e, %Y"$> </MTDateHeader> Title: <$MTEntryTitle$> <MTDateFooter> </div> </MTDateFooter> </MTEntries>
8
, this tag will
produce only the value 8
. Sometimes you would rather have your IDs padded;
in that case, you can use the pad attribute to the tag:
<$MTCommentID pad="1"$>
This will zero-pad the comment ID to six (6) digits, like 000008
.
Convert line and paragraph
breaks
in your blog configuration, paragraphs--blocks of text separated by
two line breaks--will be enclosed within <p> and </p> tags,
and for each single line breaks, a <br /> tag will be inserted.
Note that you can override the global Convert line and paragraph breaks
setting by providing this tag with the convert_breaks
attribute; if this
attribute is present, it always overrides the global setting. So, for example,
if you have the global setting turned on, but wish to turn it off for a
specific instance of this tag, you can do so like this:
<$MTCommentBody convert_breaks="0"$>
format
attribute. See Date Tag Formats for more
information.
1
. Note that the order is dependent on the sort order
(ascending or descending).
When creating the Comment Preview Template
for use in previewing comments
before they are posted to your site, you should use the following tags. All
of these tags have the same meaning as the similarly-named tags in Comments
,
above; the only different is that these tags are used for the comment that
you are previewing, whereas the others are used inside of an
<MTComments>
block.
Comments
, above.
Comment Preview
and Comment
Error
templates so that the system will know where to redirect your users
after posting a comment. To use this tag, paste this hidden input field into
the forms on your Comment Preview
and Comment Error
templates:
<input type="hidden" name="static" value="<$MTCommentPreviewIsStatic$>">
<$MTCommentPreviewState$>
tag.
A magic tag that you need to use on a comment preview page (the Comment
Preview Template
). This tag is substituted with all of the necessary comment
data in order to post the comment, as well as knowledge of whether the comment
is being posted from inline or popup comments.
The following template tags and variables apply to your archive pages and to your Master Archive Index.
MTEntries
tag to display information about each of the entries
on this archive page. For example:
<MTArchiveList> <a href="<$MTArchiveLink$>"><$MTArchiveDate$></a><br> <MTEntries> [<$MTEntryTitle$>] </MTEntries> <br><br> </MTArchiveList>
This will display a link to the archive page, followed by a list of titles of each of the entries on that page.
This tag takes one attribute: archive_type
, which specifies the type of
archives to list. This attribute is optional; if omitted, the listing will
use your Preferred Archive Type, or your Archive Type. The attribute is
useful when you have selected more than one value for the blog's Archive
Type, and you wish to list the archives for an archive type other than your
Preferred Archive Type. For example, if you have chosen to keep both
Individual
and Daily
archives, and your Preferred Archive Type is
Individual
, you can list your Daily
archives using this tag:
<MTArchiveList archive_type="Daily"> ... </MTArchiveList>
Month Day, YYYY
form.
Month Day, YYYY - Month Day, YYYY
form.
Month YYYY
form.
Using MTArchiveTitle
in combination with MTArchiveLink
is the easiest
way to create your master archive index pages, because the MTArchiveTitle
value will adapt to whatever type of archiving you choose. For example:
<MTArchiveList> <a href="<$MTArchiveLink$>"><$MTArchiveTitle$></a><br> </MTArchiveList>
No matter what archive type you choose, this will always display a useful list of your archive pages.
<MTArchiveList>
container, like this:
<MTArchiveList> <a href="<$MTArchiveLink$>"><$MTArchiveTitle$> (<$MTArchiveCount$>)</a><br> </MTArchiveList>
Daily
, Weekly
, or Monthly
archives. This is a standard date
tag; see below in Date Tag Formats for information on formatting the
date.
You can use this tag inside of an MTArchiveList
container, and you can
also use it in your Date-Based Archive Template
, outside of the
MTEntries
tag. You can use this to display a header about the dates
represented on a particular archive page--the month and year, for example:
<$MTBlogName$> Archives: <$MTArchiveDate format="%B %Y"$> <MTEntries> ... </MTEntries>
Category
archives.
You can use this tag inside of an MTArchiveList
container, and you can
also use it in your Category Archive Template
, outside of the
MTEntries
tag. You can use this to display a header about the category
of entries represented on a particular archive page. For example:
<$MTBlogName$> Archives: <$MTArchiveCategory$> <MTEntries> ... </MTEntries>
MTArchivePrevious
context, for
example, an <$MTArchiveTitle$> tag refers to the title of the previous
archive. After you end this context (with a </MTArchivePrevious> tag),
tags return to referring to the current archive.
This tag should be used in your Date-Based Archive Template
only; if you
want a similar behavior in your Individual Archive Template
, take a look at
the <MTEntryPrevious>
tag.
See the documentation for <MTArchiveNext>
(below) for an example of
usage of this tag.
MTArchiveNext
context, for
example, an <$MTArchiveTitle$> tag refers to the title of the next
archive. After you end this context (with a </MTArchiveNext> tag), tags
return to referring to the current archive.
This tag should be used in your Date-Based Archive Template
only; if you
want a similar behavior in your Individual Archive Template
, take a look at
the <MTEntryPrevious>
tag.
Here is an example of navigation that links to the previous and next archives, along with a link back to the main index for your blog.
<MTArchivePrevious> <a href="<$MTArchiveLink$>"><< <$MTArchiveTitle$></a> | </MTArchivePrevious> <a href="<$MTBlogURL$>">Main</a> <MTArchiveNext> | <a href="<$MTArchiveLink$>"><$MTArchiveTitle$> >></a> </MTArchiveNext>
The following tags can be used to output a calendar display of your entries. The calendar display is not restricted to construction using HTML tables; the tags are sufficiently generic that you could use them to create a calendar in many different forms.
<MTCalendar>
and </MTCalendar>
tags represents a single
``cell'' in the calendar (which is either a day of the month or a blank cell
representing a day in a different month).
This tag takes an optional attribute month
, which, if present, specifies the
desired calendar month and year. If the value of this attribute is the string
this
, the calendar will be created in the surrounding date context; this
means that, for example, in an archive template, you can use
<MTCalendar month="this"> ... </MTCalendar>
to represent the calendar for the month of the archive currently being viewed.
This will work for Individual
, Daily
, Weekly
, and Monthly
archives,
not for Category
archives.
If you'd like to create a calendar for a specific month, you can use the
month
attribute to specify the exact month and year, in YYYYMM
format
(example: 200112
).
If the month
attribute is not provided, the calendar will display the
current month.
1
). You can use this tag within the
<MTCalendarIfEntries>
and <MTCalendarIfNoEntries>
containers.
1
for the
first cell in the top left corner of the calendar and increases as you move
across the calendar horizontally.
This tag is different than <$MTCalendarDay$>
(above) in that the
latter tag applies only in a non-``blank'' cell (ie. an entry that represents a
day in this particular month).
format
attribute. If you only wish to display the numeric day, just use
<$MTCalendarDay$>
; you need only use this tag when you want more
date/time information in the display.
<MTCalendarWeekHeader>
and </MTCalendarWeekHeader>
will be displayed at the start of each
week.
<MTCalendarWeekFooter>
and </MTCalendarWeekFooter>
will be displayed at the end of each
week.
<MTCalendarIfBlank>
and </MTCalendarIfBlank>
will be displayed if the cell is a ``blank''
cell--that is, if it does not represent a day in this month.
<MTCalendarIfEntries>
and </MTCalendarIfEntries>
will be displayed if there are any
entries from the day represented by this cell. You can use the
<MTEntries>
tag to list all of the entries on that particular day.
For example:
<MTCalendarIfEntries> Entries from this day: <MTEntries> <a href="<$MTEntryLink$>"><$MTEntryTitle$></a><br /> </MTEntries> </MTCalendarIfEntries>
<MTCalendarIfNoEntries>
and </MTCalendarIfNoEntries>
will be displayed if there are no
entries from the day represented by this cell.
<MTCalendarIfToday>
and </MTCalendarIfToday>
will be displayed if the day represented
by the calendar cell is the current date.
Here is the markup for a fairly standard calendar display; this will display a calendar for the current month.
<table border="0" cellspacing="4" cellpadding="0"> <tr> <td colspan="7" align="center"><$MTDate format="%B %Y"$></td> </tr>
<tr> <td align="center">Sun</td> <td align="center">Mon</td> <td align="center">Tue</td> <td align="center">Wed</td> <td align="center">Thu</td> <td align="center">Fri</td> <td align="center">Sat</td> </tr>
<MTCalendar> <MTCalendarWeekHeader><tr></MTCalendarWeekHeader> <td <MTCalendarIfToday>bgcolor="#EEEEEE"</MTCalendarIfToday> align="center"> <MTCalendarIfEntries><MTEntries lastn="1"><a href="<$MTEntryLink$>"><$MTCalendarDay$></a></MTEntries></MTCalendarIfEntries> <MTCalendarIfNoEntries><$MTCalendarDay$></MTCalendarIfNoEntries> <MTCalendarIfBlank> </MTCalendarIfBlank></td> <MTCalendarWeekFooter></tr></MTCalendarWeekFooter> </MTCalendar>
</table>
NOTE: the computation of the calendar display is relatively expensive, so if you wish to place the same calendar on every page of your site, it is advisable to create the calendar in an index template, then use server side includes or PHP (or any other dynamic webserver tool) to include that file in each of your pages.
These are tags which really don't fit in any of the above categories.
MTInclude
tag to include either a template module (see Template
Modules, above, in TEMPLATES), or an external file, into another template.
<MTInclude>
takes the following attributes:
Header
, then include it
using <MTInclude>
:
<$MTInclude module="Header"$>
Local Site Path
directory, or your Local Archive Path
directory. For
example, if the file foo.html exists in your local site path directory,
you can include it in a template like this:
<$MTInclude file="foo.html"$>
This file is included in your template when the page is rebuilt; note that
this behavior should not be confused with server side includes, which will
include the external file every time the webserver serves a request for your
page. After making changes to an external file that you are including through
<MTInclude>
, then, note that you will need to rebuild your pages to
include the modified version of the page.
Last updated at
slug, for
example:
This page last updated at <$MTDate format="%B %d, %Y %I:%M %p"$>.
name
attribute, and the value using the value
attribute. You can then
retrieve the value of the variable using the tag <MTGetVar>
(below).
name
attribute
to this tag. For example
For example, you can set the value of a variable foo
in an outer template:
<MTSetVar name="foo" value="bar">
and then, in an included template module, grab the value of that variable:
<MTGetVar name="foo">
CGIPath
configuration file line
(set during installation; see the Installation Instructions). MTCGIPath
makes linking to Movable Type CGI scripts--such as mt-comments.cgi and
mt-add-notify.cgi--very simple; instead of having to type in the URL to
these CGI scripts every time you use them in your templates, instead you
should just use this tag. For example, when creating a form for posting
comments:
<form method="post" action="<$MTCGIPath$>mt-comments.cgi">
Uploaded
Image Popup Template
.
Uploaded Image
Popup Template
.
Uploaded Image
Popup Template
.
Comment Error Template
; it will be
replaced with the text of the error that occurred in the comment submission
process (for example, an invalid or missing email address).
Global tag attributes can be used in any variable substitution tag (a tag that is replaced with a value--in contrast to a container tag, which ``contains'' a set of markup and other tags). However, this does not mean that they would necessarily make sense when used in any tag; it is up to the user to determine when using a particular tag attribute might not make practical sense.
You should use a global attribute just as you would use a tag-specific
attribute: as a name="value"
pair within the tag. For example:
<$MTEntryExcerpt encode_html="1"$>
This will be replaced with an HTML-encoded version of the excerpt.
Here is a list of the global tag attributes:
1
, HTML-encodes the tag value. For example, if the value of the
tag without this attribute were Foo & Bar -> Baz
, the HTML-encoded
version would be Foo & Bar -> Baz
.
Example usage:
<$MTEntryExcerpt encode_html="1"$>
1
, encodes the tag value into a format suitable for usage in
a Javascript string value. For example, if the value of the tag without this
attribute were Foo "Bar" Baz's 1/2 Quux
, the HTML-encoded version would be
Foo \"Bar\" Baz\'s 1\/2 Quux
.
Example usage:
<$MTEntryTitle encode_js="1"$>
1
, strips all HTML tags from the from tag value. For example,
if the value of the tag without this attribute were Foo<br> Bar
,
the version without HTML tags would be Foo Bar
.
Example usage:
<$MTEntryTitle remove_html="1"$>
1
, ``dirifies'' the tag value. This means that the value of the
tag is made suitable for usage in a file or directory name: the value is
converted to lower case, HTML tags and entities are stripped, strange
characters are stripped (where strange is defined as not included in the
following set: alphanumeric characters, underscore (_
), and whitespace),
and whitespace is then converted to underscores (_
).
For example, if the value of the tag without this attribute were
Foo "Baz" is<br> Bar!
, the dirified version would be
foo_baz_is_bar
.
Example usage:
<$MTArchiveCategory dirify="1"$>
Example usage:
<$MTEntryTitle upper_case="1"$>
Example usage:
<$MTArchiveDate format="%B" lower_case="1"$>
Example usage:
<$MTEntryTitle trim_to="15"$>
The above tag will only display the first 15
characters in the entry title.
Example usage:
<$MTCalendarDay space_pad="3"$>
The above tag will pad the value 3
to `` 3
''.
Example usage:
<$MTCalendarDay zero_pad="5"$>
The above tag will pad the value 8
to 00008
.
Movable Type uses standard strftime
format strings to describe dates
and times. In any date tag, you should use the format
attribute to
specify the format string, like this:
<$MTDate format="%B %e, %Y %I:%M %p"$>
The above format is actually the default format, and creates a date looking like this:
September 20, 2001 11:44 PM
Here is a list of the format specifiers.
Thu
.
Thursday
.
Sep
.
September
.
0
if necessary. Example:
09
.
9
.
0
if necessary. Example: 04
.
0
if necessary.
Example: 4
.
0
s if necessary. Example:
056
.
0
if necessary. Example: 09
.
0
if necessary. Example: 02
.
AM
or PM
.
0
if necessary. Example: 04
.
0
if necessary. Example: 01
.
2001
.
Each blog in the Movable Type system can have multiple authors assigned to it, with varying levels of access. Movable Type uses a role-based authorization system, meaning that you assign access to authors by enabling or disabling them from performing certain ``roles'', or actions. For example, you might have one author who you trust completely; you could assign this author full permissions, to post to your blog, edit templates, edit author permissions, edit categories, etc. You might have another author who you do not trust quite as well; you could only allow this user to post entries (and edit his own posts that he has made in the past).
To edit the permissions of an existing author, login to Movable Type, then
click Add or Edit Blog Authors. Select the author name from the pulldown
menu, then click EDIT
. On this screen you can assign permissions on any
blog for which you have author-editing permissions. You can add an author to
one of your blogs by selecting that blog from the pulldown menu at the
bottom, then clicking add
.
You can edit your own authoring permissions by selecting your own name from the pulldown menu. Be careful when doing this, however, particularly with respect to turning off author-editing permissions for yourself. If you turn off your author-editing permissions, you will be unable to turn them back on.
To add a new author to the system, login to Movable Type, then click Add or Edit Blog Authors. In the Add an author section, enter the new author's username, email address, and website URL; then enter a password for the author. You can assign authoring privileges to the new author by selecting from the blogs listed at right, and checking the appropriate boxes.
Movable Type allows you to enter a list of categories, then assign one category to each of your entries. This allows you to keep track of your entries from a maintenance standpoint--for example, when listing your entries you can choose to list entries only from a particular category--and it can also be used to provide a categorization structure to your archives.
You can manage your list of categories in Movable Type by logging in,
selecting a blog, then clicking Edit Categories. Add new categories by
typing their labels into the empty text entry boxes; the system always shows
five empty boxes, so if you fill up the first five, just press SAVE
and
you'll get five more.
You can set up category archiving in your blog configuration--select a blog, then click Edit Blog Configuration. In the Archive Configuration section, under Archive Frequency check the box next to By Category.
At times, after posting a new entry, you may wish to send email to your readers, to inform them of the new entry. Movable Type makes this easy with its notification system. You can use the mt-add-notify.cgi program to provide a simple ``Notify me when new posts are added'' button, thus automating the process of adding users to your notification list. You can manage this list--either add a new address to your notification list, or delete addresses from that list--in the Edit Notifications section of Movable Type.
Notifications are never sent automatically when you post a new entry. To send a notification to your readers on a particular entry, select that entry for editing. In the Send a notification section, enter the text of the message you would like to send. You can also include the excerpt from your entry, or the entire body of your entry, by checking either of the checkboxes to the right. The message sent to your readers will include a link to the entry, followed by the message that you enter.
Movable Type comes with a simple CGI script designed to let visitors to your site add themselves to your notification list. You can use an HTML form to let visitors enter their email addresses, then submit, which will add them to the notification list. To use this script, insert this HTML code into one of your templates, where you would like the form to appear:
<form method="post" action="<$MTCGIPath$>mt-add-notify.cgi"> <input type="hidden" name="blog_id" value="<$MTBlogID$>"> <input type="hidden" name="_redirect" value="<$MTBlogURL$>"> <input name="email" size="20"> <input type="submit" value="add"> </form>
When you make changes to your templates, your configuration settings, your category names, etc., you will need to rebuild your files to see those changes reflected on your public site. Note, however, that when editing an entry, or creating a new entry, you will not need to rebuild your files: editing and creating entries automatically rebuilds the archives for that entry, and updates all of your indexes.
When you do need to rebuild your files, log in to Movable Type, select your
blog, then click Rebuild Files
. You have the choice of rebuilding all of
your files (selected by default), or only your indexes. You will need to
rebuild all of your files if you changed any of your archive templates, or
if you changed configuration settings for your archives, etc. However, if the
only things that you changed were your index templates, then you will only
need to rebuild your indexes. Rebuilding your indexes is, of course, quite a
bit faster than rebuilding all of your files.
Note that rebuilding all of your files can take a good amount of time, particularly if you are using several different types of archiving; please be patient, and do not abort the rebuilding process.
Movable Type offers an interface for uploading files--either images or
regular files--onto your webserver for use on your site. You can upload files
into either your Local Site Path
or your Local Archive Path
directories;
in addition, you can upload files into any directory beneath those two
directories.
To upload a file, log in to Movable Type, select your blog, then click
Upload File
. Browse your hard drive to choose the file you wish to upload.
Then choose where you would like to upload the to. For example, if you are
uploading an image, and you typically keep all of your images in an images
directory under your Local Site Path
, you should click the Local Site
Path
radio button, then enter images
into the text box next to it. After
choosing a destination for the uploaded file, click UPLOAD
.
If a file with the same name already exists in the destination directory, you
will have the option of overwriting the existing file; if you choose not to
overwrite the existing file, the file you uploaded will be deleted, and you
can then rename the file locally and upload it again, or resolve the issue in
some other manner. (NOTE: if you do not receive the option to overwrite the
existing file, but instead receive an error about File::Temp
not being
installed, take a look at the Installation Instructions, in the section
If you need to install File::Temp
.)
After you have uploaded a file, you have the choice of either creating a
new entry using that uploaded file, or just displaying the HTML used to link
to the file. For example, if you have uploaded an image, and would like to
create a new entry with a link to that image in a popup window, select
Create a new entry using this uploaded file
, and press POPUP IMAGE
. If
you are already editing an entry, then you won't want to create another new
entry (and perhaps lose the one that you are working on); so in that case,
click the Show me the HTML
button and click POPUP IMAGE
. This will
display the HTML code for opening the image in a popup window. You can then
copy and paste this code into the entry you are editing.
Movable Type allows you to import your entries from other weblog content management systems. If you are importing from Greymatter, Movable Type also allows you to import all of the comments on your entries into your new blog. This can be useful when you wish to start using Movable Type but already have much of your content in another system. To do this, you will first need to export your data from the other system; you can do this using the other system's standard templating functionality. Simply use a template that will produce the desired formatting that Movable Type understands for importing new entries. Templates for exporting data from Blogger, Greymatter, and Newspro are provided below.
In addition to exporting your data from another weblog CMS, you can export
your entries from Movable Type itself. This allows you to keep local backups
of your weblog content for safekeeping, as well as to transfer data between
blogs, by combining the export and import mechanisms. To export the entries
from one of your blogs, login to Movable Type, then go to the Main Menu
for
the blog you wish to export. Then click Import & Export Entries
, and
follow the instructions under Export Entries
.
NOTE: be careful when exporting data from Internet Explorer; all versions of Internet Explorer have a bug where data marked as plain text can be intrepreted as HTML. The symptom of this bug is that all of your exported data will run together onto one line. If this is the case, use Netscape when exporting data.
After your content has been exported from the other system, you must move your data files over to the system where Movable Type runs, so that Movable Type can find them. Then you can use the import mechanism to import those entries into Movable Type.
<Blogger> AUTHOR: <$BlogItemAuthor$> DATE: <$BlogItemDateTime$> ----- BODY: <$BlogItemBody$> -------- </Blogger>
Blog Filename
to a different filename; this will prevent
you from overwriting your main index file.
Formatting
, set your blog to display all of your posts on the main
index page. There is no explicit setting for this; instead, you should
change the number of days displayed on your front page (Show N days' posts
on main page
) higher than the number of days that you have been blogging.
Date/Time Format
to the format MM/DD/YYYY HH:MM:SS AM|PM
. (Note:
the format will not look like this in the menu; instead it will be the
current time, formatted.)
Convert Line Breaks
to No
.
Archive Frequency
to No Archive
. This will prevent your archives
from being overwritten with the new template.
Publish
your blog. You will end up
with a single file with all of your posts, formatted using the above template,
at the location specified in your Settings. Download this file to your local
hard drive.
Now skip down to Importing Entries, below.
These instructions describe the process of exporting all entries and comments from Greymatter into a format suitable for import into Movable Type.
NOTE: if you have already imported your Greymatter entries into Movable
Type, and now wish to import only your comments, use the Exporting Greymatter
Comments Only
instructions, below.
Edit Templates
; then click
Edit Main Index-Related Templates
.
Main Index Template
with the following:
{{logbody}}
Index Entry Template: Standard Entries
template with the
following (note: you must remove the indentation from the following lines
when pasting into your Greymatter template):
TITLE: {{entrysubject}} DATE: {{monthmonth}}/{{dayday}}/{{yearyear}} {{hour}}:{{minuteminute}}:00 {{ampm}} AUTHOR: {{author}} ----- BODY: {{entrymainbody}} ----- {{entrycomments}} --------
Index Entry Template: Extended Entries
template with the
following (note: you must remove the indentation from the following lines
when pasting into your Greymatter template):
TITLE: {{entrysubject}} DATE: {{monthmonth}}/{{dayday}}/{{yearyear}} {{hour}}:{{minuteminute}}:00 {{ampm}} AUTHOR: {{author}} ----- BODY: {{entrymainbody}} ----- EXTENDED BODY: {{entrymorebody}} ----- {{entrycomments}} --------
Date Grouping Template
, Entry Separator
Template
, and Stay At Top Index Entry Template
.
Return to the main templates menu, then click Karma & Comments-Related
Templates
.
Comment Appearance Template
, as in Step 2.
Comment Appearance Template
to the following (note: you must
remove the indentation from the following lines when pasting into your
Greymatter template):
COMMENT: AUTHOR: {{commentauthor}} EMAIL: {{commentauthoremailabsolute}} URL: {{commentauthorhomepageabsolute}} DATE: {{monthmonth}}/{{dayday}}/{{yearyear}} {{hour}}:{{minuteminute}}:00 {{ampm}} {{commentbody}} -----
Return to the main templates menu, then click Miscellaneous Templates
.
Paragraph Separator
and Line Separator
templates,
as in Step 2.
Paragraph Separator
template to two carriage returns, and do
the same for your Line Separator
template.
Return to the main menu, then click Configuration
.
Index filename
, so as not to overwrite your existing blog.
Days to keep on main index
so that it is higher than the number of
days that you have been blogging. This will have the effect of placing all
of your entries on your main index.
Return to the main menu, then click Rebuild Files
.
Rebuild Files
menu, you only want to rebuild your main index page,
so click the Rebuild Main Index File
button.
After this is done, you will end up with a single file with all of your posts, formatted using the above templates, at the location specified in your configuration. Download this file to your local hard drive.
Now skip down to Importing Entries, below.
If you have already imported your Greymatter entries into Movable Type, and now wish to import just the comments from those entries, you can do this using the following steps. Note that these instructions will only work if:
Authored on
dates) on those entries
after importing them; Movable Type will use the entry timestamps to determine
which comments match up with which entries. Thus, if you have changed the
timestamp on an entry, Movable Type will not be able to match up any comments
on that entry.
Here are the steps for exporting just your Greymatter comments:
Edit Templates
; then click
Edit Main Index-Related Templates
.
Main Index Template
with the following:
{{logbody}}
Index Entry Template: Standard Entries
template with the
following (note: you must remove the indentation from the following lines
when pasting into your Greymatter template):
DATE: {{monthmonth}}/{{dayday}}/{{yearyear}} {{hour}}:{{minuteminute}}:00 {{ampm}} NO ENTRY: 1 ----- {{entrycomments}} --------
Index Entry Template: Extended Entries
template with the
following (note: you must remove the indentation from the following lines
when pasting into your Greymatter template):
DATE: {{monthmonth}}/{{dayday}}/{{yearyear}} {{hour}}:{{minuteminute}}:00 {{ampm}} NO ENTRY: 1 ----- {{entrycomments}} --------
Date Grouping Template
, Entry Separator
Template
, and Stay At Top Index Entry Template
.
Return to the main templates menu, then click Karma & Comments-Related
Templates
.
Comment Appearance Template
, as in Step 2.
Comment Appearance Template
to the following (note: you must
remove the indentation from the following lines when pasting into your
Greymatter template):
COMMENT: AUTHOR: {{commentauthor}} EMAIL: {{commentauthoremailabsolute}} URL: {{commentauthorhomepageabsolute}} DATE: {{monthmonth}}/{{dayday}}/{{yearyear}} {{hour}}:{{minuteminute}}:00 {{ampm}} {{commentbody}} -----
Return to the main templates menu, then click Miscellaneous Templates
.
Paragraph Separator
and Line Separator
templates,
as in Step 2.
Paragraph Separator
template to two carriage returns, and do
the same for your Line Separator
template.
Return to the main menu, then click Configuration
.
Index filename
, so as not to overwrite your existing blog.
Days to keep on main index
so that it is higher than the number of
days that you have been blogging. This will have the effect of placing all
of your entries on your main index.
Return to the main menu, then click Rebuild Files
.
Rebuild Files
menu, you only want to rebuild your main index page,
so click the Rebuild Main Index File
button.
After this is done, you will end up with a single file with all of your posts, formatted using the above templates, at the location specified in your configuration. Download this file to your local hard drive.
Now skip down to Importing Entries, below.
Change Settings
.
News Files Path
to point to a different directory, so as not
to overwrite your public files; you may need to create a new directory for
this.
Archive Files Path
to point to the same directory as used in
Step 2.
Archive/Hide News
setting to Archive
.
News Age
to a number greater than the number of days you've
been blogging with NewsPro.
Archive Type
to One Archive
.
Monthly Archive Links Page
to point to a new, unique file, so
as not to overwrite your public links page.
12/24 Hour Clock
to the 12 hour system.
Date Format
to the following:
<Field: Month_Number>/<Field: Day>/<Field: Year> <Field: Hour>:<Field:Minute>:00 <Field:AMPM>
News Display
to the following (note: you must remove the
indentation from the following lines when pasting into your NewsPro template):
TITLE: <InsertSubject> DATE: <InsertDate> AUTHOR: <InsertName> ----- BODY: <InsertNews> --------
Submit Settings
button. Do not rebuild yet.
Advanced Settings
link.
Advanced Settings
scroll down to about the middle of the page and
find the NumberLimit
setting; make sure that it is set to zero (0
).
CreateAnchors
setting (around the middle of the page), and set
it to No (Off)
.
Now skip down to Importing Entries, below.
Now that you have exported all of your entries from your other content management system, you are ready to import the entries into Movable Type.
Your existing blogs
list.
Import Entries
.
If importing the entries as you, check the Import as me
box.
If creating new authors, you will need to set a password which will be
used when creating each of the new authors in the system. You should also
leave the Import as me
box unchecked.
NOTE: if the name of an author listed for one of the entries you are importing is already being used by an author in the Movable Type system, the entry will be assigned to the existing author, and a new author will not be created.
If you do not choose a default category, the entries will not be assigned to a
particular category (unless the entries you are importing use the CATEGORY
key to specify their category).
If you choose a default category, and one or more entries use the CATEGORY
key in the list of exported entries, the CATEGORY
key will override the
default category, for those entries using the CATEGORY
key; all other
entries will be assigned to the default category.
Title Start HTML
and Title End HTML
values are used to identify
a post title within the body of an entry. This is useful when importing
entries from Blogger, for example, because Blogger posts do not have the
concept of a separate title field. If you have named your posts consistently
through the use of HTML tags, however, Movable Type can parse your blog
entries to find those titles. For example, if all of your entry titles look
like this:
<font class="title">I am a title</font>
Then you could use a value for Title Start HTML
of
<font class="title">
and a value for Title End HTML
of
</font>
to automatically set the titles of your entries when importing. If found, the title, along with the surrounding HTML, will be removed from the body of your entry.
If you do not fill in these values, or if the relevant HTML cannot be found for a particular entry, the first five (5) words of the entry are used as the title, instead.
IMPORT
to import
your entries.
NOTE: You should now remove all of the files that you imported from the import directory, so that if or when you run the import process again at some later date, the entries you just imported will not be re-imported.
You will need to rebuild all of your files in order to generate your archives for the new imported entries.
Movable Type features a full implementation of the Blogger XML-RPC API (where
applicable). The only two methods that are not supported by Movable Type are
getTemplate
and setTemplate
, due to the differences between Blogger's
template system and Movable Type's template system. Usage of the XML-RPC API
requires that your webserver have both LWP::UserAgent
and SOAP::Lite
installed; if yours does not, the Installation Instructions can tell you how
to install them.
Following are the XML-RPC methods supported by Movable Type:
appkey
, String blogid
, String username
, String
password
, String content
, boolean publish
Return value: on success, String postid
of new post; on failure, fault
appkey
, String postid
, String username
, String
password
, String content
, boolean publish
Return value: on success, boolean true value; on failure, fault
appkey
, String postid
, String username
, String
password
, boolean publish
Return value: on success, boolean true value; on failure, fault
appkey
, String blogid
, String username
, String
password
, int numberOfPosts
Return value: on success, array of structs containing ISO.8601
dateCreated
, String userid
, String postid
, String content
; on
failure, fault
Notes: dateCreated
is in the timezone of the blog blogid
appkey
, String username
, String password
Return value: on success, array of structs containing String url
,
String blogid
, String blogName
; on failure, fault
appkey
, String username
, String password
Return value: on success, struct containing String userid
, String
firstname
, String lastname
, String nickname
, String email
, String
url
; on failure, fault
Notes: firstname
is the Movable Type username up to the first space
character, and lastname
is the username after the first space character.
NOTE: the value of appkey
is ignored by Movable Type in all XML-RPC
methods.
You can use Movable Type's XML-RPC implementation with existing tools like BlogBuddy and Jericho (it has been tested with these two tools; it will most likely work with other tools, as well). For example, to set up BlogBuddy to post to your Movable Type blog, follow these instructions:
blog(s)
using BlogBuddy's posting
interface.
If, when you try to load mt.cgi into your browser--or mt-load.cgi or mt-check.cgi during the installation process--then the problem is that your webserver does not have CGI scripting enabled in its configuration.
If you run your web site on a hosted provider, you will need to email the support for this provider and ask them to turn on CGI scripting for your account (or for the webserver on a whole); this is not something that you can configure yourself.
If you run your own webserver, or if you have access to the webserver configuration files--and the privileges to restart the webserver, after modifying the configuration--you can use these steps to enable CGI scripts on your webserver. The following instructions assume that you are running Apache.
Directory
or Location
block that configures the webroot for
the server.
Inside of that block, add this line:
Options +ExecCGI
Directory
or Location
block, add the line
AddHandler cgi-script .cgi
CGI scripts should now execute, instead of merely displaying their source.
500 Internal Server Error
is the general webserver error that occurs when
something goes wrong--in particular, when something goes wrong when trying to
execute a CGI script.
Here is a list of diagnostics for trying to fix this error:
-w
at the end of the first
line in each file; this setting turns on warnings in Perl, and it is important
that it be left on.
To determine the location of Perl on your webserver, take a look at the support pages for your hosting service. Alternatively, if you have a shell (command line) account, and are familiar using it, you can log in to that account that type:
$ whereis perl
This will give you the location(s)
of Perl on your system.
If, when you first view Movable Type, the images and styles do not show up properly in your browser, you will need to move the images, documentation, and stylesheet to a different location. The reason for this is that you installed Movable Type into your cgi-bin directory, because--presumably--it was necessary to do so on your server. But hosting non-CGI files out of the cgi-bin directory causes problems, because the webserver sometimes tries to execute the images, as if they were programs.
To fix this, you will need to re-upload the images directory (images), the documentation directory (docs), and the stylesheet (styles.css) to a different directory, outside of your cgi-bin directory. Then, edit the mt.cfg file, and add this line:
StaticWebPath /path/to/dir/
where /path/to/dir/ is the URL to the directory containing images and styles.css. For example, if images is located at /movable-static/images/, you would use
StaticWebPath /movable-static/
This should fix the problem.
The problem: you log in to the system and get the Main Menu
; but every
link you click on that screen brings you back to the login screen.
The reason for this is likely that you have cookies disabled in your browser. Movable Type uses a cookie to store your authentication credentials; in this cookie, your password is one-way encrypted, so this is not a security risk. If you do not allow this cookie, however, Movable Type has no way of knowing that you have already successfully logged in, so it will present you with a login prompt when you try to do anything.
To fix this problem, you will need to enable cookies in your browser.
The problem: you are logged in to Movable Type; then you logout, and try to login as another user (for example). But you are still logged in as yourself.
This is probably due to your browser having several versions of the Movable
Type login cookie. The reason this might happen is that the cookie is dependent
on the domain name; so if you have two different domain names that access the
same Movable Type installation, and you use both to get there, you will get
two versions of the Movable Type cookie. If one domain name is a substring of
the other domain name--for example, if one domain is www.foo.com
, and the
other is foo.com
--then you will need to log out of both sessions in order
to truly logout. To do this, load Movable Type on both domains, and log out
of both sessions.
Because of this, if possible it makes sense to always access Movable Type through one single domain name.
NOTE: another symptom of this problem is that notification messages sent
through the Edit an entry
screen never reach the members of your
notification list.
If you know that users are posting comments on your site, and you are not
receiving them, you should first check your blog configuration to ensure that
Email new comments?
is checked.
If it is, then this is most likely a problem with the path to the sendmail program on your webserver; this is the program used to send email. Movable Type looks in three locations for sendmail: /usr/lib/sendmail, /usr/sbin/sendmail, and /usr/ucblib/sendmail. These are the three most common locations for sendmail on Unix machines. If your version of sendmail is at a different location, here are instructions for telling Movable Type what that location is:
SendMailPath /path/to/sendmail
where /path/to/sendmail
is the path to sendmail that you determined in
Step 1.
That's it; if the location to sendmail is correct, you should now be able to receive email notifications of new comments.
If you have tried the above steps to get sendmail working, or if you know that your webserver doesn't have sendmail--for example, Win32 machines do not have sendmail--Movable Type allows you to send email messages through SMTP. To do this, you will need to install the Mail::Sendmail Perl module; if you are on Win32 machines, you can do this using Activestate's ppm tool. Launch ppm, then at the prompt, type
install Mail::Sendmail
and ppm will do all of the work to install the module. If you are on a non-Win32 machine, and you need (or prefer) to use SMTP, you can download the distribution from here:
http://www.cpan.org/modules/by-modules/Mail/Mail-Sendmail-0.78.tar.gz
Unpack the archive using an extraction program, then connect via FTP to your
webserver. Open the directory where you installed Movable Type, then open the
extlib directory; then create a new directory called Mail
. Then open
the Mail
directory, and upload the file Sendmail.pm from the archive
into the Mail
directory.
After you have installed Mail::Sendmail, you will need to configure Movable Type to send mail using SMTP. To do so, edit your mt.cfg file, and add the line
MailTransfer smtp
By default, Movable Type will try to use the SMTP server on the webserver (on
localhost
); if you need to change this, add another line
SMTPServer address.of.smtp.server
Save (and re-upload, if necessary) your mt.cfg file, and you're done. Movable Type should now send email through the SMTP server.
When rebuilding a page, Movable Type first writes the page data to a temp file, then renames the temp file to the actual file name. The temp file is named with an extension of .new; for example, if the file index.html is being rebuilt, the temp file would be named index.html.new. Movable Type does this to prevent corruption of your public files; if, for some reason, the rebuild process is killed in the middle of writing data to a file, that file will not be complete, and will appear corrupted to a web browser.
The process of writing to temp files requires that permissions on the
Local Site Path
directory be set to 777; some users can not--or would
rather not--set the permissions this liberally, and will then receive errors
when Movable Type is unable to write to the .new temp files. If this is
the case for you, you can turn off the use of temp files. To do so, edit
your mt.cfg file, and add the line
NoTempFiles 1
This will tell Movable Type not to write data to temp files, and you should no longer receive errors when rebuilding.
404
error page that comes with MTThe Movable Type distribution includes a file index.html in the main Movable Type directory; when you upload this file to your webserver, it prevents users from viewing the contents of the directory listing. This is not meant to provide bulletproof security, but it keeps away curious viewers.
The version that ships with Movable Type is rather plain, so if you'd like to improve it on your server, just edit the file index.html; it's just a standard HTML file.
If you are using Apache as your webserver, you can use a different technique to prevent users from viewing your directory listings:
Options -Indexes
to that file.
If you use this technique, you can remove the index.html file from the directory; the webserver will then prevent viewers from listing the contents of the directory.
When you change hosting providers (or just move to a different server at the same provider), it is possible that the two servers have different versions of the Berkeley DB library; this is the library that Movable Type uses to store your data. When you copy the DB files from one host to another, if the two hosts have different versions of Berkeley DB, the new host will not be able to read the files from the old host.
This can be fixed by converting the DB files over to the format used by the new library version; this is accomplished in several different ways, depending on the Berkeley DB versions involved. The files that need to be converted are all of the files in your db directory whose filenames end in either .db or .idx (the .lock files do not need to be converted).
The following steps require that you have shell access to your server, and imply that you are somewhat familiar with running Unix commands; if this is not the case, you should ask your hosting provider to help you.
$ cd <db_dir> $ db_upgrade *.db *.idx
If your server has db_upgrade, this will convert all of your DB files over to the new format. If this works, you're done, and you can skip the following steps; Movable Type should now work.
command not found
--then you will need to use the following
method to convert your data. This method dumps out all of the data from your
DB files, then loads it into new versions of those DB files.
The program used to dump the contents of your DB files is called either one of two things: db_dump, or db_dump185. To determine which program you need to use, first try running the following command in your shell account:
$ cd <db_dir> $ db_dump author.db
If this command is successful, you will see a screenful of data dumped out. If it is unsuccessful, you will get an error message; in this case, try using the following command:
$ db_dump185 author.db
Again, if the command is successful, you will see a screenful of data. If this also fails, then you will need to contact your hosting provider.
$ db_dump -f author.db.data author.db $ mv author.db.old $ db_load -f author.db.data author.db $ chmod 666 author.db
You will need to run these four commands for each file in your db directory whose name ends in .db or .idx. After you have done so, you're done, and Movable Type should now work.