Widon’t for Movable Type
26th Aug 2006
Widon’t for Movable Type is a plugin to prevent widows from appearing in titles and entry headers. Widows are single words, left on their lonesome on a line at the end of a paragraph, and generally look poo.
Widon’t simply adds a non-breaking space entity between the last two words of an entry title, so if the last word has to wrap, it takes a friend with it.
Widon’t for Wordpress was originally released a few days ago by Shaun Inman, but I didn’t want to be left out as an MT user, so I’ve ported it across to Perl. All credit for the idea and PHP version goes to Shaun, any failures in this MT version are down to me.
Widon’t for Movable Type v1.4 (2008-07-11)
Unzip the file and place Widont.pl in the plugins directory of your Movable Type installation.
For titles, add the global filter
widont="1" to your entry title tags:
<mt:EntryTitle widont="1" />
To prevent widows in header tags used in entries, add the widont filter to the appropriate MTEntry tag:
<mt:EntryExcerpt widont="1" /> <mt:EntryBody widont="1" /> <mt:EntryMore widont="1" />
I’m no Perl ninja, so if there are any problems let me know.
This project is also hosted on github.