in reply to Movable Type: Highlighting Perl Code
I just started using Movable Type this week, and went through the same search, but didn't find anything that worked the way I wanted. So I ended up writing a plugin to do text formatting using my Text::Multi module. It may not work for you as-is, but it's short enough that it could get you started writing a plugin that does work just the way you want it...
# JasonKohles::TextMulti plugin # Copyright 2008 Jason Kohles # <email@jasonkohles.com> # http://www.jasonkohles.com/ # package JasonKohles::TextMulti; use strict; use warnings; our $VERSION = '0.1'; our $ID = '$Id$'; use base qw( MT::Plugin ); use Text::Multi; MT->add_plugin( __PACKAGE__->new( { id => 'textmulti', name => 'TextMulti', version => $VERSION, author_name => 'Jason Kohles', author_link => 'http://www.jasonkohles.com/', plugin_link => 'http://code.jasonkohles.com/MTTextMulti/', doc_link => 'docs.html', description => 'Text::Multi Format Filter', registry => { text_filters => { text_multi => { label => 'Text::Multi', docs => 'docs.html', code => sub { my $parser = Text::Multi->new( default_type => 'Markdown' ); $parser->process_text( $_[0] ); return $parser->render; }, }, }, }, } ) );
| We're not surrounded, we're in a target-rich environment! |
|---|
|
|---|