How to Enable/Install SyntaxHighlighter in blogspot

1. Log into your blogger account and click the blog you want to operate.
2. Click "Template" label from left column
3. Click "Edit HTML" label.
4. in the opening window, locate close head tag: , and put the following contents before close head tag:

























5. Save template.
6. Put your Script or Code inside the PRE tags and define class with brush name in your blog post.But you have to make sure that the code you are going to put inside the PRE tag has to be escaped, like "<a>" has to be converted to &lt;a&gt;
To do so, you could use this site. Escape html code.

<pre class='brush:[brushname];'>
  <!--Put Your Code Here (must be HTML escaped)-->
 </pre>
7. Always edit your code in HTML view editor. After editing your content in another editor, always paste the edited content in HTML view mode too.

No comments:

Post a Comment

Datatable static image not found on the server

When you use ```datatables.min.css``` and ```datatables.min.js``` locally, instead of datatables CDN, you may have encountered that ```sort...