Recently in MT Plugin Solutions Category

MediaManager beta4

| 1 Comment

Byrne Reese has released MediaManager beta4... an updated, overhauled, "new and improved" MT32-friendly replacement for BookQueueToo, as well as MTAmazon32v1.0 (repackaged and updated MTAmazon). Very cool! Check out the screenshots for a walk-through and you'll be impressed, too.

Installation (on MT32b2) was not too difficult. First, I edited mt-config.cgi to specify my mt-static path (even though I do have it in the default location). Then I uploaded MTAmazon32.pl and MediaManager into my plugins directory (making sure to CHMOD 755 mmanager.cgi). In System Overview/Plugins I configured MTAmazon32 with my Amazon subscriber ID and cache location. Then I configured MTAmazon32's Amazon associate ID through each blog's plugin settings.

Oh, I forgot about MediaManager's static folder. Rename it mmanager and move it to your mt-static directory.

I think that did it. Hope I didn't forget anything... oh yeah, the cache folder... I actually forgot to create one and there's been no fussing about it. Is it not required with MTAmazon32? (I have gone ahead and created it.)

Anyway, the awesome new "Review" feature looks... well.. awesome!! Byrne brilliantly incorporated the Amazon image hacks that he had described previously on his site. I finally figured out how to use it. After you create your review (I had to do it as a draft), go to your entries and edit it by selecting a new Text Formatting option: "MediaManager: Layout1", select Publish, then save. You will have a very cool and nicely formatted review entry. Unfortunately, this plugin does not (yet!) have a php counterpart, so the review entries will not work with dynamic archives. :-(

FYI, MediaManager beta4 results are in the "books" section on my beta blog as well as in the left sidebar on this blog.

BookQueueToo, it is a-changin'

As if there wasn't already enough to get excited about with MT3.2 just around the corner, Byrne announced the coming transition of BookQueueToo to MediaManager which will take advantage of all the ninja sweetness of MT's new goodies. Fun!

And here's a somewhat related freebie... somewhere on some MTAmazon related sites (should have bookmarked them) suggestions have been made to add "/ref=nosim/" to Amazon URLs so the link takes you directly to the page with the "add to cart" link, resulting (supposedly) in a better referral rate. Here's an example:

<a href="<MTAmazonLink>/ref=nosim/"><img src="<MTAmazonMediumImage>"></a>

I also tacked /ref=nosim/ onto my associate id in iTunes NowPlaying plugin for the same result. (example: username-20/ref=nosim/) Hopefully, it won't screw anything up. So far so good.

Activity Log Plugin Errors

My MT Activity Logs were FULL of plugin errors pointing to Blacklist, BookQueueToo, Blogroll, and QuickLinks. (essentially, any plugins that are in their own dedicated directories inside mt/plugins) These plugins have always worked without fail from the front end, so I was mystified at the copious error messages suggesting they could not be found.

Here is just one sample of a variety of similar messages:

Plugin error: /home/user/domains/domain.net/public_html/mt/plugins/Blacklist/Blacklist.pl Can't locate Blacklist/Plugin.pm in @INC (@INC contains: plugins/Blacklist/lib ./plugins/BookQueueToo/lib /home/user/domains/domain.net/public_html/mt/

Searching the MT Support Forums and google pointed me to a very simple solution. In each plugins .pl file I edited the "use lib" line to include the full path per the following example:

use lib /home/user/domains/domain.net/public_html/mt/plugins/PluginName/lib

Voila! No more error messages. :)

Creating a "Sticky" Entry

Sometimes I want to make a post "sticky" so it stays at the top of my entry list for an extended length of time, even after posting newer entries. There are several ways to accomplish this.

One, perhaps the simplest, is to post-date the "sticky" entry so that it will stay in place as long as that date is still in the future or no entry has usurped it's place by post date.

Another option is to just hard-code the sticky text into your index template where you want it. (yuck, but it works)

A third option and my preferred method is to use the MTEntry plugin which gives you the MTEntry tag, allowing you to call one specific entry id...

php includes in cgi templates

I wanted to use a php include in my Comment Listing Template, which is actually run inside comments.cgi. An ordinary php include wouldn't do the trick. Another plugin to the rescue... MTIncludePlus. This provided the perfect solution in the form of new container tag, MTIncludeURL. (FYI, this plugin also adds tags MTIncludeFile and MTIncludeModule.) Here's an example of what I used to call a rotating tagline into my banner in dynamic templates that run as cgi:

<MTIncludeURL timeout="15">http://domain.com/tagline/rotator.php</MTIncludeURL>

(obligatory reminder: code is all one line)

This also works in the default search templates.

php includes in dynamic archive templates

I was having a heck of a time calling includes into dynamic archive pages (php files, no extensions). The syntax I used in my Main Index template was NOT working in my dynamic archives. What I found out was that I was using a php shortcut syntax which is not enabled on all servers (and perhaps in my case not in all cases? not sure about that yet - I'll look into an .htaccess solution although I have no reason to believe there is one - just a gut instinct to try)

These worked in the main index, but not in archives:

<? include "http://domain.com/tagline/rotator.php"; ?>

or
<? include "tagline/rotator.php"; ?>

This syntax works in both index AND archives:

<?php include ("http://domain.com/tagline/rotator.php"); ?>

or
<?php include ("links.inc"); ?>

Cool.

Update: having a big "duh!" moment. Forgot about MTInclude as well as plugin MTIncludePlus. The latter provided a solution (new tag MTIncludeURL) for calling includes into my comments.cgi page. (comment listing template,etc) Here's an example of what I used to call a rotating tagline into my banner in dynamic templates that run as cgi:

<MTIncludeURL timeout="15">http://domain.com/tagline/rotator.php</MTIncludeURL>

(obligatory reminder: code is all one line)

NOTE: MTInclude and MTIncludePlus tags slow down the rebuild process. (I only use these tags when a regular php include won't do.) To speed up these tags, consider the MTFastInclude plugin at MTExtensions.

About this Archive

This page is an archive of recent entries in the MT Plugin Solutions category.

MT Installation is the previous category.

MT Source Hacks is the next category.

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