Wednesday, December 21, 2011

General - Beautifying code snippets in your blogs

Syntax Highlighter is a javascript library that helps you format your code snippets within a blog or some other stuff sharing site.

You'll need only to add this block at the end of your tag <head> in your html template:


















The trick is to embed your code within something like this:
<pre class="brush:html">
Your 'HTML' code goes here
</pre>

Sources:
http://alexgorbatchev.com/SyntaxHighlighter/integration.html
http://www.cyberack.com/2007/07/adding-syntax-highlighter-to-blogger.html

No comments:

Post a Comment