Friday, 18 November 2011

Adding SYNTAXHIGHLIGHTER in Blog..

How to add SYNTAXHIGHLIGHTER to your blog.?
for adding syntaxhighlighter in our blog we need to apply some changes to our blog template...
1) Frist of all select your blog and go to design.
2) there select Template it will show your selected template.
3) then go to edit html of your template


4) it will ask for confirmation for editing html directly select proceed
5) it will show one text area contain design of your template there you need to search this tag
</head> use Ctrl + F to find this tag



6) now use this block of javascript and link and past it just above the </head>



7) now select save template and it will close the edit html window.


8) now syntax highlighter will added to your blog..
9) for using syntax highlighter to highlight your syntax use pre tab like this...
<pre class="brush:c-sharp"> 
  // your code will be placed between this pre tag 
</pre> 
for more information on brush type please see this link...
http://alexgorbatchev.com/SyntaxHighlighter/manual/brushes/
10) Now its done enjoy...!!!!!


No comments:

Post a Comment