Designed to be used with the Template Installer plugin, Template Exporter is a plugin for Movable Type that enables you to easily export your blog templates in a way that can be shared, distribute, or even sold to to others.
New in Version 1.1
- Support for the new "Template Sets" feature in MT 4.1. Starting with MT 4.1, when you create a new blog, you can choose from multiple template sets to use. Template Exporter v1.1 enables you to export your current templates into sets that you can chose when creating new blogs, in a very easy way. More info on this feature below.
- The code has been optimized to improve performance.
Note: templates exported with version 1.1 of Template Exporter cannot be install with older version of the Template Installer plugin, you will need Template Installer v1.1 (or higher).
Also note that version 1.1 can be used with both MT 4.01 and MT 4.1.
The easist way to describe how Template Exporter works is to show you. The first video below shows how you can export all of a blog templates:
And the the following video shows how you can export only selected templates:
Potential Uses of Template Exporter
This plugin can be put to use in several ways:
- To create a "backup" of their templates, which can be re-installed later if desired.
- To copy a set of template from one blog (or installation) to another (some call this "template portability").
- To share your templates with friends, or post them for download on your blog.
- To package and sell your customized template designs.
- To deploy a common template design to multiple blogs in an MT installation.
- To distribute blog Widgets.
- To distribute blog templates with MT plugins, providing easy installation.
How it Works (if you care)
Template Exporter provides two main functions:
- It extracts your templates and saves them in files named according to the template_identifier or template_name, such as main_index.mtml. Each template gets stored in its own file. (Technical note: if a template has an "identifier" field defined in the database, then it will be used for the file name. If not, a "dirified" version of the template name will be used, so "Main Index" will become "main_index".)
- It automagically creates a YAML file named config.yaml, which defined the configuration information for template set. This includes things like the type and name of the template, and for index templates, the output file and "rebuild with indexes" setting. For example of a Template Exporter config.yaml file, click here.
These files are then saved in their own directory inside a "template_exporter" subdirectory of your blog. You can then use FTP or other means to download the directory and files from there, and subsequent shares the exported template or use with Template Installer to install them on another blog or installation.
Movable Type 4.1 includes a feature called Templatee Sets that enables you to choose a template set when you create a new blog. Template Exporter supports this template set format, so you can export your favorite template set and use it as one of the template set choices. No code or plugin creation required. Just use these easy steps:
- Go to the Templates area for the blog you want.
- Choose the "Export Templates" link from the "Actions" menu on the right side of the page.
- Give the new set a name and export it.
- Now take the exported set (including the folder that contains the set - for example, if you named it "Cool Style Templates" then the folder would be 'cool_style_templates') and move it into the 'plugins' directory.
- Create a new blog and your set will be among the options!
- Download and extract the zip file and upload the contents of the 'plugins' folder to the 'plugins' directory of your MT installation.
- Go the blog you want, then Design > Templates then choose the "Export Templates" link from the lower right. (Or, to export only selected templates, check the boxes of the templates you want, then choose "Export Template(s)" from the "more actions" drop-down box, then click "Go".)
- Give the template set a name, using only letters, numbers, and spaces, and then click Continue.
Get Template Exporter
Template Exporter is free to MT Hacks members for non-commercial use:
Downloads: <$MTAjaxRatingVoteCount id="1" type="templateexportererdownloads"$>
Developer/Designer License - Free
Template Exporter is free for commercial use by MT developers and template designers for use on their own MT installations for the purposes of exporting templates for public sale or for distribution with plugins. Developers and Designers can contact me for a copy.
Comments and suggestions are welcome.