Acronym Plugin

Acronym is a plugin for Movable Type that adds acronym tags to known acronyms.

This text:

This is a XHTML test

becomes

This is a <acronym title="Extensible HyperText Markup Language">XHTML</acronym> test

which in the web browser is shown like this:

This is a XHTML test

Installation

Just unzip the acronym.zip into the plugins directory of your Movable Type installation.

You might have to change the perl path in mt-acronym.cgi from #!/usr/local/perl/bin/perl -w to #!/usr/bin/perl -w

Now add acronym="1" to the <$MTEntryBody> tag in your templates. Like this:

<$MTEntryBody acronym="1" $>

Rebuild your files!

Styling

I'd recommend the following CSS style to style your <abbr> and <acronym> tags:

ABBR, ACRONYM {border-bottom: 1px dotted #000; cursor: help;}

Limitations

  • Acronyms in links are not replaced. XHTML in <a href="http://gemal.dk">is XHTML bad?</a> is not replaced.

Acronym vs. Abbreviation

I'm aware that most of the so called acronyms that this module substitues aren't acronyms but in fact abbreviations. But since some browsers dont support the <abbr> tag I decided to stick with the <acronym> tag.

Read more about the war between <abbr> and <acronym> here and here.

Links

Version history

Version 2.0
  • MT3.x support. Acronym now shows up in the main page of your MT installation under Configure Active Plugins
  • More acronyms added to acronym.db. Total is now 347
Version 1.0
  • More acronyms added to acronym.db. Total is now 212
Version 0.7
  • More HTML tags ignored
  • Better detection of HTML tags to ignore
  • Acronyms like HTML! are also supported now
  • Strict warning fixed
  • More acronyms added to acronym.db. Total is now 170
Version 0.6
  • Fixed loading of database (acronym.db) under mod_perl by using MT::ConfigMgr
  • Easier regexp management in acronym detection
  • More acronyms added to acronym.db. Total is now 162
Version 0.5
  • Much faster algoritm
  • Acronyms in text like AOL/Time/Warner are also supported now
  • More acronyms added to acronym.db
Version 0.4
  • Variable name change. No code change
  • More acronyms added to acronym.db
Version 0.3
  • removed unused use Data::Dumper
  • added acronym.txt file
  • renamed acronym.txt into acronym.db
Version 0.2
  • skip text inside acronym and abbr tags
  • allow some more chars to be in front of sustituted acronyms
  • added even more acronyms to acronyms.txt file
.
You're here: Home - Movable Type - Acronym Plugin
Get the Mozilla Firefox browser