Google Code Prettify - 輕量級的語法上色工具

星期二, 9月 08, 2015

程式碼高亮語法產生器

dp.SyntaxHighlighter
http://pydoing.blogspot.tw/2010/11/syntaxhighlighter-blogger.html

Online syntax highlighting
https://tohtml.com/

Online Syntax Highlighter
http://highlight.hohli.com/

SyntaxHighlighter 在 Blogger 的使用教學
http://pydoing.blogspot.tw/2010/11/syntaxhighlighter-blogger.html
<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/shThemeDefault.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/shBrushPhp.js' type='text/javascript'/>
 
<script language='javascript'>
SyntaxHighlighter.config.bloggerMode = true;
SyntaxHighlighter.config.clipboardSwf = 'http://alexgorbatchev.com/pub/sh/current/scripts/clipboard.swf';
SyntaxHighlighter.all();
</script>

<pre name="code" class="brush: php;">...</pre>



Google Code Prettify - 輕量級的語法上色工具
HEAD加入
<script src="https://google-code-prettify.googlecode.com/svn/loader/run_prettify.js"></script>
使用
<pre class="prettyprint lang-scm">
...
</pre>