Trapped in a vicious circle

MT 3.0 lets plugin authors add a doc_link to their plugins, which then winds up linked on the Main Menu. Create an MT::Plugin object and tell MT to add it:

my $plugin = new MT::Plugin({name => "CategoryTrackbackTags, v0.2",
                             description => "Adds tags for category trackback data",
                             doc_link => ""

and you wind up with <a href="">CategoryTrackbackTags, v0.2</a>, ready to remind people why they installed that in the first place. A nice little touch.

The most sensible place to send the doc_link is to the weblog post where I “announce” the plugin. That post needs a download link, so the plugin has to be there, ready to download. To put the plugin there, it needs to have a doc_link, leading to the entry. For extra trapped-by-simple-things fun, I actually considered writing a plugin_action script (a CGI that gets called with the name of the page and the object id, from a link inserted in pages like entry or comment editing by calling MT->add_plugin_action('entry', 'drafturi.cgi', 'Get draft permalink');), just so I could save a draft, have it tell me what the permalink will be, stick that in the plugin, upload, then publish. Then I realized that even I can figure out what month and year it is, and convert spaces to underscores. (Plus, I’d have to upgrade this MT install to 3.0 to have it work, and to do that…)


Comment by Michael Pate #
2004-05-23 20:04:08

I just upgraded Third Superpower to 3.0 tonight. Or to be more correct… I backed up the MySQL database and then did a new install. It took sometime to reinstall the plugins but other than that it wasn’t difficult. I probably spent the longest time trying to figure out how to incorporate the new comment tags.

Comment by Phil Ringnalda #
2004-05-23 20:30:21