<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Olaf's Thoughts About Development &#187; SourceCode</title>
	<atom:link href="http://www.monien.net/blog/index.php/tag/sourcecode/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.monien.net/blog</link>
	<description>Delphi Programming, .NET Philosophy, Web development and more ...</description>
	<lastBuildDate>Wed, 21 Jul 2010 10:55:31 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
		<item>
		<title>Using SyntaxHighlighter on Blogs or Web sites</title>
		<link>http://www.monien.net/blog/index.php/2008/04/using-syntaxhighlighter-on-blogs-or-web-sites/</link>
		<comments>http://www.monien.net/blog/index.php/2008/04/using-syntaxhighlighter-on-blogs-or-web-sites/#comments</comments>
		<pubDate>Mon, 28 Apr 2008 22:00:00 +0000</pubDate>
		<dc:creator>Olaf Monien</dc:creator>
				<category><![CDATA[.NET]]></category>
		<category><![CDATA[Miscellaneous]]></category>
		<category><![CDATA[Delphi]]></category>
		<category><![CDATA[SourceCode]]></category>
		<category><![CDATA[Syntax Highlighting]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://www.monien.net/blog/index.php/2008/04/using-syntaxhighlighter-on-blogs-or-web-sites/</guid>
		<description><![CDATA[If you have a development realted blog or Web site, then you probably paste source code examples from time to time. Using Alex Gorbatchev&#8217;s SyntaxHighlighter makes your snippets look very pretty.  Update: For WordPress there is a SyntaxHighlighter Plus plugin, which is also based on the code below.  I&#8217;ve updated my posts here on the [...]]]></description>
			<content:encoded><![CDATA[<p>If you have a development realted blog or Web site, then you probably paste source code examples from time to time. Using Alex Gorbatchev&#8217;s SyntaxHighlighter makes your snippets look very pretty.<span id="more-180"></span> <em></em></p>
<p><em>Update: For WordPress there is a <a title="SyntaxHighlighter Plus" href="http://wordpress.org/extend/plugins/syntaxhighlighter-plus/" target="_blank">SyntaxHighlighter Plus</a> plugin, which is also based on the code below.  I&#8217;ve updated my posts here on the new WP based blog system to use that plugin.</em></p>
<p>I just found Alex Gorbatchev&#8217;s excellent <a href="http://code.google.com/p/syntaxhighlighter/" target="_blank">SyntaxHighlighter</a> on Google Code. It&#8217;s JavaScript based and makes it very easy to pretty-print your source code examples. It comes with modules for:</p>
<ul>
<li>C#</li>
<li>C++</li>
<li>CSS</li>
<li>Delphi</li>
<li>Java</li>
<li>Javascript</li>
<li>PHP</li>
<li>Python</li>
<li>Ruby</li>
<li>SQL</li>
<li>VisualBAsic</li>
<li>XML</li>
</ul>
<p>It&#8217;s completely modular, so if you need Delphi only, then you don&#8217;t have to load all other modules. Usage is very easy, just add the following to your HTML template that drives your blog or source code pages:</p>
<pre class="brush: html">
&lt;script src=&quot;/js/shCore.js&quot; type=&quot;text/javascript&quot;&gt;&lt;/script&gt;
&lt;script src=&quot;/js/shBrushDelphi.js&quot; type=&quot;text/javascript&quot;&gt;&lt;/script&gt;
&lt;script type=&quot;text/javascript&quot;&gt;&lt;/script&gt;
</pre>
<p>shCore.js is about 13KB, the language modules and clipboard.swf are just two KB in average. If you need Delphi and C# then just add shCSharp.js to the list above. To show a piece of source code you insert the raw source inside a &lt;pre&gt;&lt;/pre&gt; tag pair. The actual formatting will be done by SyntaxHighlighter.</p>
<pre class="brush: html">
&lt;pre class=&quot;delphi&quot;&gt;
var
  s: string;
begin
  s := &#039;Hello World&#039;;
end;
&lt;/pre&gt;
</pre>
]]></content:encoded>
			<wfw:commentRss>http://www.monien.net/blog/index.php/2008/04/using-syntaxhighlighter-on-blogs-or-web-sites/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
	</channel>
</rss>
