Note: I only managed to get it to work for the old version (1.5.x) but as you can see on my blog that version is still eminently usable. As you will see there is no particular reason why the approach sketched below won't work for newer versions and I will look at it again but for now we'll make do with what works.
Step by step installation of the syntax highlighter in Blogger
- Download the package from Google Code
- Unpack the rar file
- Copy the contents of the CSS stylesheet into Bloggers advanced CSS configuration
shCore.jsplus the contents of any file suitable for the languages you want to highlight in your blog. For this blog I copied
script tags. Add the contents of
shCore.js first, followed by the contents of the other files. Finish with a line like
dp.SyntaxHighlighter.HighlightAll('code');. The resulting contents need to look something like this:
HighlightAll()method is called. You can of course arrange to have this method called in an onLoad event, in which case you can probably choose to place the gadget anywhere.
The final step is to open Blogger's template editing page. Select Advanced from the left most column and then select Add CSS from the column next to it. This will open up a text editor where you can insert the contents from the file
SyntaxHighlighter.css (it can be found in the
Styles directory). Click Apply to Blog and you're done.