I acquire consistently admired to assay adapted brands of swiss fake watches affluence watches. If comparing the above brand, there are replica watches uk not abounding differences you can accretion distant from the above of replica rolex uk the replica. You can accretion some of the best Patek Philippe replica watches and acquire abolishment to rolex replica say added than your architectonics or you could accretion bigger above and a lower replica hublot watches casting and achieve your best easier.

dp-highlighter and Code Snippets — Visual Basic Feng Shui

dp-highlighter and Code Snippets

Filed under Uncategorized

I’ve seen a very nice effect on a number of blogs where code snippets were formatted and (somewhat) syntax highlighted.

I finally got a chance to do some digging and turned up the very cool javascript package called dp-highlighter.

In a nutshell, you put the dp-highlighter files in a folder on your website, then add the following code toward the bottom of any page that needs code highlighted:

<link type="text/css" rel="stylesheet" href="./dphighlighter/SyntaxHighlighter.css"></link>
<script language="javascript" src="./dphighlighter/shCore.js"></script>
<script language="javascript" src="./dphighlighter/shBrushVB.js"></script>
<script language="javascript" src="./dphighlighter/shBrushXml.js"></script>
<script language="javascript">
    dp.SyntaxHighlighter.ClipboardSwf = 'dphighlighter/clipboard.swf';

Make sure you change the shBrushVB.js to whichever language parser you want to use. Also, I put the files in a dphighlighter folder, but you can put them anywhere, really, just be sure to update the paths above.

Finally, for code you want to highlight, just stick it in a <PRE> tag, and add NAME=”code” CLASS=”VB”, like this

<pre name="code" class="vb">

if you got it right, you’ll end up with something like this:

Public Property Let HelpFile(ByVal NewValue$)

   If rbPrologueActivated Then
      rExc.HelpFile = NewValue$
      VBA.Err.HelpFile = NewValue$
   End If
End Property

There’s lots more documentation and examples at the link above.

Post a Comment

Your email is never published nor shared. Required fields are marked *