1 (edited by vsbyte 20-03-2013 14:10:05)

Topic: Google Code Prettify

Another plugin for syntax highlight for your blog. This plugin based on prettify.js library (Google Code Prettify). Automatically find blocks of code, detects a language and highlights it.

Support 28 languages:

Apollo
Basic
Clojure
CSS
Dart
Erlang
Go
Haskell
Lisp, Scheme
Llvm
Lua
Matlab
MLs:F#, Ocaml,SML
Mumps
Nemerle
Pascal
Protocol buffers
R, S
RD
Scala
SQL
TCL
Latek
Visual Basic
CHDL
Wiki
XQ
YAML

Upload plugin and enable it in "Dashboard -> Manage plugins".

Open file "/themes/your_theme/templates/default.bit", find:

<!-- Plugin::Analytics -->
    <?php
        if( isset($plugins_by_name['analytics']) )
        {
            echo $plugins_by_name['analytics']->get_html();
        }
    ?>

and add after:

<!-- Plugin::prettify -->
    <?php
        if( isset($plugins_by_name['prettify']) )
        {
            echo $plugins_by_name['prettify']->get_html();
        }
    ?>

That's it! Enjoy!

Download

Re: Google Code Prettify

This was for an older version of Nb, correct?

Re: Google Code Prettify

Link is broken.