‘auto-links’ demo
Source
<pre class="brush: php; auto-links: false">
/** http://alexgorbatchev.com */
'http://alexgorbatchev.com'
</pre>
Result
/** http://alexgorbatchev.com */
'http://alexgorbatchev.com'
‘class-name’ demo
Source
<style>
.class_name_demo { border: 2px solid #000; }
</style>
<pre class="brush: php; class-name: 'class_name_demo'">
/** http://alexgorbatchev.com */
'http://alexgorbatchev.com'
</pre>
Result
/** http://alexgorbatchev.com */
'http://alexgorbatchev.com'
‘collapse’ demo
Source
<pre class="brush: plain; collapse: true">
hello there!
This is collapsed code.
</pre>
Result
Hello there!
This is collapsed code.
‘first-line’ demo
Source
<pre class="brush: plain; first-line: 10">
this is now tenth line,
and this is eleventh!
</pre>
Result
this is now tenth line,
and this is eleventh!
‘gutter’ demo
Source
<pre class="brush: php; gutter: false;">
/** http://alexgorbatchev.com */
'http://alexgorbatchev.com'
</pre>
Result
/** http://alexgorbatchev.com */
'http://alexgorbatchev.com'
‘highlight’ demo
Source
<pre class="brush: plain; highlight: 2">
1
2
3
</pre>
<pre class="brush: plain; highlight: [1, 3]">
1
2
3
</pre>
Result
1
2
3
1 x = y;
2 mysql_query($query);
3X++
‘html-script’ demo
Source
<pre class="brush: php; html-script: true">
<html>
<body>
<div style="font-weight: bold"><?= str_replace("\n", "<br/>", $var) ?></div>
<?
/***********************************
** Multiline block comments
**********************************/
$stringWithUrl = "http://alexgorbatchev.com";
$stringWithUrl = 'http://alexgorbatchev.com';
ob_start("parseOutputBuffer"); // Start Code Buffering
session_start();
?>
</body>
</html>
</pre>
Result
<html>
<body>
<div style="font-weight: bold"><?= str_replace("\n", "<br/>", $var) ?></div>
<?
/***********************************
** Multiline block comments
**********************************/
$stringWithUrl = "http://alexgorbatchev.com";
$stringWithUrl = 'http://alexgorbatchev.com';
ob_start("parseOutputBuffer"); // Start Code Buffering
session_start();
?>
</body>
</html>
‘smart-tabs’ demo
Source
<pre class="brush: plain; smart-tabs: true">
hello there! ya!
12 hello ya!
</pre>
<pre class="brush: plain; smart-tabs: false">
hello there! ya!
12 hello ya!
</pre>
Result
hello there! ya!
12 hello ya!
hello there! ya!
12 hello ya!
‘tab-size’ demo
Source
<pre class="brush: js; tab-size: 4">
123 123 123
1 2 3
</pre>
<pre class="brush: js; tab-size: 8">
123 123 123
1 2 3
</pre>
Result
123 123 123
1 2 3
123 123 123
1 2 3
‘toolbar’ demo
Source
<pre class="brush: php; toolbar: true;">
/** http://alexgorbatchev.com */
'http://alexgorbatchev.com'
</pre>
<pre class="brush: php; toolbar: false;">
/** http://alexgorbatchev.com */
'http://alexgorbatchev.com'
</pre>
Result
/** http://alexgorbatchev.com */
'http://alexgorbatchev.com'
/** http://alexgorbatchev.com */
'http://alexgorbatchev.com'