SyntaxHighlighter is a fully functional self-contained code syntax highlighter developed in JavaScript.
To get an idea of what SyntaxHighlighter is capable of, have a look at the demo page.
Easily post syntax-highlighted code to your site without having to modify the code at all. As seen on WordPress.com.