SyntaxHighlighter for plain text on blogspot
I just followed the below link 开发者_高级运维to set up syntaxhighlighter on my blog:
http://www.craftyfella.com/2010/01/syntax-highlighting-with-blogger-engine.html
But as given in this link, i tried to use the brush plain
but i am getting the error as can't find brush for : plain
Any suggestions?
I use to use GIT hub to do this work in pretty much 8 simple steps,
1) Browse to https://gist.github.com 2) Add a Gist Description (optional) 3) Add a file name with an extension (extension will be used to add syntax highlighting) 4) Add your code snippet which need to be added to your blog post 5) Click “Create Public Gist” button at the bottom 6) Click on the “embed” link and copy the script generated
This is all from Gist side. Now to Blogger,
- Paste the script where you need to add the code snippet
- Make sure to select the option “Interpret typed HTML” under Post Options -> Compose Settings
I found this steps in this blogspot
Remember how you added the files at the top of the HTML of your page for the essential SyntaxHighlighter CSS files and JavaScript brush files? The website tutorial you found does not add the brush plain to its list of brushes. All you have to do is add this (http://agorbatchev.typepad.com/pub/sh/3_0_83/scripts/shBrushPlain.js) JavaScript file under the other brush files that look like this:
<link href='http://alexgorbatchev.com/pub/sh/current/styles/shCore.css' rel='stylesheet' type='text/css' />
<link href='http://alexgorbatchev.com/pub/sh/current/styles/shThemeEclipse.css' rel='stylesheet' type='text/css' />
<script src='http://alexgorbatchev.com/pub/sh/current/scripts/shCore.js' type='text/javascript' />
<script src='http://alexgorbatchev.com/pub/sh/current/scripts/shBrushCss.js' type='text/javascript' />
<script src='http://alexgorbatchev.com/pub/sh/current/scripts/shBrushJScript.js' type='text/javascript' />
<script src='http://agorbatchev.typepad.com/pub/sh/3_0_83/scripts/shBrushXml.js' />
Basically, just add this under your other brushes:
<script src='http://alexgorbatchev.com/pub/sh/current/scripts/shBrushPlain.js' type='text/javascript' />
精彩评论