Recently in This Site Category

Upgraded to MT 5.2.2

| No Comments

I decided to upgrade from MT 5.0.4 to MT 5.2.2. Why? Just for the hell of it. I've been home sick for a week with a bad chest/head cold that complicated my asthma. The upgrade would have been more smooth if I hadn't updated the templates in a fit of confusion and lost all custom templates and widgets I'd created. Fun stuff.

A full rebuild of MT on Friday took hours and hours and hours. Unreasonable. I've thought again about converting to WordPress but just can't bring myself to go through the conversion.

Changing the length of the Basename in Movable Type's settings will change the Basename length for new entries. The Basename for existing entries will not change.

I tried using Brad Choate's EntrySetBasename plugin (which was written for MT4.x) to change the Basename for all existing entries, but the plugin would not install without an error in the Movable Type 5 admin interface - and MT would not work with the plugin installed.

I wanted all blog entries to have up to the maximum of 250 characters for the Basename length, and I was willing to delete, if necessary, all entries (about 775) and import them with new Basenames. So, these are the steps I took (I am not responsible for any problems you may encounter. Backup all files first.):

  1. Export all blog entries to a backup file (important in case you mess up)
  2. Back up the source blog to a backup file (same reason)
  3. Create an index template in the format used for MT entry export files
  4. Change the Basename field in the template to the EntryTItle but with hyphens removed and dirify-ed with spaces changed to underscores
    • change:
    • to:
      BASENAME: <$mt:EntryTitle regex_replace="/-/g","" dirify="_" trim_to="250"$>
  5. Set an Output File for the template
  6. Publish the template to generate the output file (which is an export file of all entries with a maximum 250-character Basename)
  7. Copy the output file into the mt/import/ directory
  8. Delete all entries from the blog
  9. Import the output file that is now in the mt/import directory
  10. After the import finished, remove the output file from the mt/import directory (important so you don't import the entries again by mistake)
  11. Check to make sure entries with long EntryTitles also have long Basenames - and they do!

The export template format I used is below.

Another note to myself and others who may not know this…

If your MT installation is in one domain, but your blog or website is in a different domain (on the same server) - and the mt-static directory is located outside the MT installation, the stylesheet included with an MT theme won't work unless you set the StaticWebPath in the mt-config.cgi file to include the full URL where the MT installation is located.

So, in the mt-config.cgi file, you need to change:

StaticWebPath  /mt-static/



Go to the MT Documentation page about StaticWebPath.

Another note to myself and others who may not know this…

Changing Settings > General> Archive Settings > File Extension to "php" does not change the extension for the "Main Index" index template. Check other templates to ensure the extension on the Output File setting is what you want.

To change the Main Index file extenion to "php", you must manually change that template's Output File from "index.html" to "index.php".

A note to myself and others who may not know this…

If your MT installation is in one domain, but your blog or website is in a different domain (on the same server), MT's Search Widget and Tag Search (the link on the tag names) won't work unless you set the CGIPath in the mt-config.cgi file to include the full URL where the MT installation is located.

So, in the mt-config.cgi file, you need to change:

CGIPath /cgi-bin/mt/



Go to the MT Documentation page about CGIPath.

Upgrading to Movable Type 5.04

| No Comments

This morning, I decided to upgrade to the latest version of Movable Type - v. 5.04 - from a new installation (vs. upgrading over the old version). After creating a test site and seeing how the new interface worked, I exported entries from the MT 4.x blog and imported them into the new MT 5.x blog. All went perfectly from what I can tell right now.

I'm still working on copying custom templates and widgets to the new system, but at least the home page is working - even though the sidebar isn't quite right...

So, things may be wonky here for a while... And, links will be broken here and there since I'm now using MT's default filename schema.

Responding to blog comments

| No Comments

Whew. I have just responded by email to a bunch of blog comments going back to early last year. I replied only to those for which I had an answer or other response.

I will try to be better at responding to future comments… (but no promises - life gets in the way sometimes).

Use sed to change multiple filenames

| 1 Comment

I wanted to replace all hyphens in all filenames starting with 2003- and ending with .php. Here's how I did it using sed (no guarantees, no warranties, use at your own risk!):

  1. Backup the files!
  2. Change to the directory you want to make the changes in.
  3. Then, to make sure the right filenames will be changed, list the filenames using the following sed command (modify "2003-*.php" and the sed search and replace strings for your situation):

    for filename in 2003-*.php; do echo $filename | sed \e 's/\-/\_/g'; done

  4. When you're sure the above sed command is listing the right filenames, change it as follows (modify "2003-*.php" and the sed search and replace strings for your situation):

    for filename in 2003-*.php; do newname=`echo $filename | sed \e 's/\-/\_/g'`; mv $filename $newname; done

Note the use of the backtick character (`) (also known as backquote) which, on my keyboard, is located to the left of the "1" key. The backtick character is used in addition to the single quote character (').

[Update January 4, 2009] I totally forgot that I could have used the "rename" command instead of sed! There is control over which underscore in a filename is changed. More about renaming files using "rename".

Upgraded to MT 4.23

| No Comments

Believe it or not, it has taken most of the time between 9:00am and 3:30pm to upgrade from Movable Type 4.1 to Movable Type 4.23. The process would have been smoother if I hadn't had to create a bunch of redirects in .htaccess when I upgraded to MT 4.1 (because I changed from using _ to - in filenames and directory names). I've now removed all those redirects (if old links on other websites aren't corrected by now, oh well!).

A few things to note about the upgrade to MT 4.23:

  • The /mt-static/images/tab-bg-yah.gif file is missing from the downloaded zip file - search Google for tab-bg-yah.gif to find it.
  • The path used by the HTML files that display popup images changed from the directory designated during an image upload to the /assets_c/YYYY/MM/ directory. For example, it changed from: to
  • The thumbnail image created by MT during an image upload used to be stored in the directory designated during the image upload (such as /images2008/). It is now stored in the /assets_c/YYYY/MM/ directory where YYYY/MM is the month and year the image was uploaded.
  • The large image is still stored in the directory designated during the image upload (such as /images2008/)
  • Upgrading the MySQL database (mt-upgrade.cgi) didn't work properly using Firefox 2.x (kept hanging - not continuing - so I switched to IE 7.x to finish the process.

[Update January 4, 2009] Well, as it turns out, the assets_c directory can be renamed by adding a single line to the config file (via Assets Directory of MovableType). As I had been doing prior to the upgrade to MT 4.23, he uses .htaccess to change underscore characters to a hyphen (dash). To change the name of the assets directory: add this line to the mt.config.cgi file:

AssetCacheDir /assets_c

MT 4 Plugins I've installed

| No Comments

Movable Type 4.01 came with these plugins pre-installed:

  • Feeds.App Lite
  • MultiBlog 2.0
  • StyleCatcher 2.0
  • Template Backup and Refresh 1.2
  • Textile 2.04
  • WXR Importer 1.0
  • Weblog Cloner 2.0
  • Widget Manager 1.0
  • Markdown 1.0.1 and SmartyPants 1.5.1 (plugin set)
  • SpamLookup - Lookups 2.11, SpamLookup - Link 2.11, SpamLookup - Keyword Filter 2.1 (plugin set)

I have installed these plugins:

* These plugins have proven very helpful! So far, I haven't used the others.

And, I tried these plugins but removed them due to Internal Server Error messages (500 Server Error) or 3-minute publish times for 1 entry or a comment. These plugins displayed errors in the MT 4 Activity Log.

  • Bookmarks 1.0b2
  • MT-Quicktags
  • reCaptcha - just could not get it to work (this is the version included in the MT 4 "mt/extras/examples/plugins/reCaptcha" folder)

[Update July 3, 2008] Additional plugins I've installed for MT version 4.1 (some a while back, some today):

* These plugins have proven very helpful!

Trusted Commenters 1.2 doesn't work consistently. But, TinyTuring has proven very helpful by ending spam comments on this blog.

Note: It seems that the pre-installed-with-MT-4.01 Weblog Cloner 2.0 was renamed Blog Cloner 2.0 with MT 4.1.

Sketch of Cheryl

About Cheryl

Enjoys crocheting, gardening, cats, NASCAR (especially Tony Stewart and Kyle Busch!), reading, photography, snorkeling in Kailua-Kona with sea turtles, Sizzler's Mega Bacon Cheeseburgers, hot and iced decaf coffee, dark chocolate, color (yarn, fabric), playing around with web technologies - not necessarily in that order! Still very much a beginner with quilting, knitting, and sewing. Donates crocheted lap blankets.

List maker, detail-oriented, organized, leans heavily toward perfectionism. ISTJ. Libra.

January 2017

Sun Mon Tue Wed Thu Fri Sat
1 2 3 4 5 6 7
8 9 10 11 12 13 14
15 16 17 18 19 20 21
22 23 24 25 26 27 28
29 30 31        
Disclaimer: This is a personal website - my place of self expression. The views expressed are mine alone and do not necessarily reflect the views of my employer or any other organization I am a member of or affiliated with.
Creative Commons License
This blog is licensed under a Creative Commons License.
Powered by Movable Type 5.2.2

About this Archive

This page is an archive of recent entries in the This Site category.

Tech is the previous category.

Thread Projects-Crochet is the next category.

Find recent content on the main index or look in the archives to find all content.

Cat playing with strand of yarn.


Recent Comments

  • debbbie30612: Thanks Cheryl I had a swatch of this pattern many read more
  • adam.primecp: Love this! I work with AllFreeCrochet and have been trying read more
  • Hello... I am looking for a Cheryl Lambert that is read more
  • Please please also let me know how to contact read more
  • ancyvan66: I am working on one of these right now. I read more
  • joebrazauskas: Cheryl, I really meant to respond on your page about read more
  • Hi, just came across your blog today and wanted to read more
  • jeaninkpr: Thanks so much - this is exactly what I was read more
  • Marion Vanstone: Hi Cheryl I received an email from Katherine Keselowsky (aka read more
  • Sandra: 'A Dozen & One Tunisian Dishcloths' by Annie's Attic I read more