可讓程式碼變得更好看
官網: http://alexgorbatchev.com/SyntaxHighlighter/
安裝方式 參考
http://alexgorbatchev.com/SyntaxHighlighter/manual/installation.html
Brush name
|
Brush aliases
|
File name
|
bash, shell
|
shBrushBash.js
| |
cpp, c
|
shBrushCpp.js
| |
css
|
shBrushCss.js
| |
js, jscript, javascript
|
shBrushJScript.js
| |
java
|
shBrushJava.js
| |
perl, pl
|
shBrushPerl.js
| |
php
|
shBrushPhp.js
| |
py, python
|
shBrushPython.js
| |
xml, xhtml, xslt, html, xhtml
|
shBrushXml.js
|
程式碼用下面語法包起來
<pre class=
"brush: java"
>
</pre
"
>
public class Hello { public static int gvar; public static void say(String s) { int x = 10; System.out.print(s+x); } public static void main(String[] argv) { float y = 0; say("Hello, world\n"); } }
<pre class=
"brush: python"
>
</pre
"
>
print("Hello, world!")
沒有留言:
張貼留言