SyntaxHighlighter 3.0.83

Fork Me On GitHub
whats new?
SyntaxHighlighter is an open source Java Script client side code syntax highlighter.
donate download installation autoloader configuration @syntaxhighlight

API

SyntaxHighlighter.regexLib

This object has a number of preconfigured commonly used regular expressions.

multiLineCComments
Matches: /\* ... \*/
singleLineCComments
Matches: // ...
singleLinePerlComments
Matches: # ...
doubleQuotedString
Matches: " ... \" ... "
singleQuotedString
Matches: ' ... \' ... '
multiLineDoubleQuotedString
Matches: " ... \" ... \n ... "
multiLineSingleQuotedString
Matches: ' ... \' ... \n ... '
url
Matches: ...://...
phpScriptTags
Matches: <? ... ?>
aspScriptTags
Matches: <% ... %>
scriptScriptTags
Matches: <script ...>... </script>

SyntaxHighlighter API

SyntaxHighlighter is the top level object and contains a number of functionality and predefined variables.

NameTypeDescription
allFunctionStatic function which process all elements on the page and performs syntax highlighting.
HighlighterClassThe base class for a brush.
regexLibObjectCommonly used regular expressions.