Skip to main content
3 of 4
replaced http://meta.stackexchange.com/ with https://meta.stackexchange.com/

You can't highlight a language with Markdown. You need to outsource this to external libraries. Such as.

  1. SyntaxHighlighter
  2. Google Code Prettify
  3. Pygments

EDIT: The StackOverflow way of doing this is to have a comment at the top. Like so.

<!-- language: lang-js -->

Just replace lang-js with one of the language codes or a tag to set the language to the language associated with that tag. For example.

<!-- language: C# -->

Highlighting for C# is associated with the C# tag.

user184498