FlashTextFormatter plugin for WordPress

We’ reusing the FTF wordpress-plugin to view code snippets/samples. It’s a really nice plugin which automatically colors /highlights your ActionScript (and even more: js, php, python). Just put some [ ftf ] brackets around your code … the plugin does the rest.

We’re actually using this fix from zeuslab (FTF w/ SWFObject).

You can also include whole as-files – but my first attempts all failed. After debugging the script for a while, I found a small bug inside the FlashTextFormatter.php. To fix it you just have to change one line of code:

// change line 86 from
$ftf_props[$ftf_counter]['file'] = "index.php";

// to sth like this
if(ftf_getProp('file', $ftf_counter) != "")
$ftf_props[$ftf_counter]['file'] = ftf_getProp('file',$ftf_counter);

Now everything works fine :)