Is there a javascript plugin available that will color example code to make it look as it does in a text editor? Using the php.net prinf page as an example, I want to convert this:
<code>
<?php<br>
$num = 5;<br>
$location = 'tree';<br>
$format = 'There are %d monkeys in the %s';<br>
printf($format, $num, $location);<br>
?>
</code>
to this
<code>
<span style="color: #000000">
<span style="color: #0000BB"><?php<br>$num </span>
<span style="color: #007700">= </span>
<span style="color: #0000BB">5</span>
<span style="color: #007700">;<br></span>
<span style="color: #0000BB">$location </span>
<span style="color: #007700">= </span>
<span style="color: #DD0000">'tree'</span>
<span style="color: #007700">;<br><br></span>
<span style="color: #0000BB">$format </span>
<span style="color: #007700">= </span>
<span style="color: #DD0000">'There are %d monkeys in the %s'</span>
<span style="color: #007700">;<br></span>
<span style="color: #0000BB">printf</span>
<span style="color: #007700">(</span>
<span style="color: #0000BB">$format</span>
<span style="color: #007700">, </span>
<span style="color: #0000BB">$num</span>
<span style="color: #007700">, </span>
<span style="color: #0000BB">$location</span>
<span style="color: #007700">);<br></span>
<span style="color: #0000BB">?></span>
</span>
See google-code-prettify