tips and tricks for movable type

edit mt.cfg from within MT
October 12, 2002

With the integration of MT Search into the latest version of Movable Type, there is now a lot more to the mt.cfg file than just the basic installation configuration options. I decided to make my mt.cfg file available for editing through the MT interface for easier access.

Update 11.01.02: Please note that the latest version of MT (2.51) now has SafeMode turned on by default, which will prevent you from implementing this tip - for very good reasons. If you have a multi-author blog, you really don't want another author being able to mess around with your mt.cfg file (or do other nasty things).

So this tip is only recommended for single-author blogs. You can turn off SafeMode (which will enable you to use this tip) by adding this line to your mt.cfg file:

SafeMode 0

Don't blame me if it backfires on you in a multi-author blog - the warning has been issued!

I created a new Template Module in my Site Management blog (more on that in another entry soon) called CFG. In the "link this template to a file" field, I put the full server path to my mt.cfg:

/FULL/PATH/TO/MT.CFG

(If you have trouble determining your full path, run mt-check.cgi and look at the "current working directory" for clues - and remember the beginning /.)

I left the Module Body blank and then pressed SAVE. The contents of mt.cfg then appeared in the Module Body, and voila! I can now make changes whenever I want, without relying on an external text editor and FTP client.

P.S. This tip isn't limited to your mt.cfg file - it's also an excellent way to manage the default and alternate search templates as well! My default search template is a module in my Site Management blog; the alternates are modules in each specific blog to which they belong.

Comments

Girlie,
I am interested in the following:
1) The "more/hide more" drop-down feature.
2) I'm also interested in a Comment drop-down feature instead of a small javascript window that opens.
3) Recent comments and Entries With Most Comments on your sidebar.

I'd like to suggest putting a permanent link right by those features. For example, on the recent comments, you might want to have hyperlinked word like "CODE" so when someone wants a feature like that, they could just click on that link instead of searching the archives. Just a thought.

Thanks again!

by SunMark | 11.01.02 06:13 AM

Such a GREAT TIP -- even a complete MT NEWBIE like me can make this work so thank you thank you thank you, ms. smartie pants!!

by Todd | 02.08.03 07:49 AM

Post a comment

(If you haven't left a comment here before, you may need to be approved by the site owner before your comment will appear. Until then, it won't appear on the entry. Thanks for waiting.)

TrackBack: 1
(URL: http://www.thegirliematters.com/sf/mt-track.cgi/104)

» Isn't she clever?
Excerpt: Do you need a more convenient way to tweak your mt.cfg file? If you're interested in doing things like stopping
Weblog: Live in the Delirious Cool
Tracked: 10.14.02 07:20 AM