一区二区三区日韩精品-日韩经典一区二区三区-五月激情综合丁香婷婷-欧美精品中文字幕专区

分享

How to Add and Use SyntaxHighlighter 3 for Bl...

 dzh1121 2013-09-12

The latest version of Syntax Hihglighter has been released and there are quite a few changes in the way things work now. This version was named Syntax Hihglighter 3.0.83.


NEW FEATURES IN 3.0.83
  • Dynamic Brush Loading

    SyntaxHighlighter comes with almost 30 brushes out of the box. One of the most requested feature has been the ability to dynamically load them without having to load them all on the same page.
  • No Flash Copy to Clipboard

    Earlier, Flash was being used to copy the code to clipboard. This has now been removed and a simpler & better way to do this has been implemented. Also, the user can now simply double-click anywhere in the code to select it and then use the standard CTRL+C to copy it.
  • Code Selection

    This is also now part of the SyntaxHighlighter as it allows you to select the code with your mouse and then copy and paste it without straight into your code without any additional effort.
  • Add Title

    Now you can add a title to the code block by title="title name" parameter to the <pre> tag.
  • More under the hood

    More improvements and changes under the hood like better CSS support, easier integration with CommonJS & node.js, etc.

INSTALLATION

Before you could get in to the process, I recommend you to back up your template.

1. Navigate to Dashboard > Design > Edit HTML
2. Find </head>
3. Copy below code and paste it just before the </head> tag
<!-- Syntax Highlighter 3.0.83 START -->
<link href='http:///pub/sh/current/styles/shCore.css' rel='stylesheet' type='text/css'/>
<link href='http:///pub/sh/current/styles/shThemeDefault.css' rel='stylesheet' type='text/css'/>
<script src='http:///pub/sh/current/scripts/shCore.js' type='text/javascript'/>
<script src='http:///pub/sh/current/scripts/shBrushBash.js' type='text/javascript'/>
<script src='http:///pub/sh/current/scripts/shBrushCss.js' type='text/javascript'/>
<script src='http:///pub/sh/current/scripts/shBrushJava.js' type='text/javascript'/>
<script src='http:///pub/sh/current/scripts/shBrushJScript.js' type='text/javascript'/>
<script src='http:///pub/sh/current/scripts/shBrushPerl.js' type='text/javascript'/>
<script src='http:///pub/sh/current/scripts/shBrushPhp.js' type='text/javascript'/>
<script src='http:///pub/sh/current/scripts/shBrushSql.js' type='text/javascript'/>
<script src='http:///pub/sh/current/scripts/shBrushVb.js' type='text/javascript'/>
<script src='http:///pub/sh/current/scripts/shBrushXml.js' type='text/javascript'/>
<script language='javascript' type='text/javascript'>
SyntaxHighlighter.config.bloggerMode = true;
SyntaxHighlighter.all();
</script>
<!-- Syntax Highlighter 3.0.83 END -->
4. Save your template.

NOTE:
Whenever you have to write some codes in your posts, click on "Edit HTML" tab of your post editor and write the codes between the following tags

<pre class="brush: js">
Your code here
</pre>


To add title in your code add title="Title Here" it's look like the code below:


<pre class="brush: js" title="Title Here">
Your code here
</pre>


For an example :

<pre class="brush: js" title="This is a title, check it out!">
<b:includable id='comments' var='post'>
  <div class='comments' id='comments'>
    <a name='comments'/>
    <b:if cond='data:post.allowComments'>
      <h4>
        <b:if cond='data:post.numComments == 1'>
          1 <data:commentLabel/>:
        <b:else/>
          <data:post.numComments/> <data:commentLabelPlural/>:
        </b:if>
      </h4>
</pre>


Will display like the below image on your blog post.


Before adding any script within <pre>, encode the script using HTML entities. You can encode your script using our Adsense Parser / HTML Entities Encoder.

    本站是提供個人知識管理的網(wǎng)絡(luò)存儲空間,所有內(nèi)容均由用戶發(fā)布,不代表本站觀點(diǎn)。請注意甄別內(nèi)容中的聯(lián)系方式、誘導(dǎo)購買等信息,謹(jǐn)防詐騙。如發(fā)現(xiàn)有害或侵權(quán)內(nèi)容,請點(diǎn)擊一鍵舉報(bào)。
    轉(zhuǎn)藏 分享 獻(xiàn)花(0

    0條評論

    發(fā)表

    請遵守用戶 評論公約

    類似文章 更多

    亚洲伊人久久精品国产| 日韩国产亚洲欧美激情| 亚洲国产丝袜一区二区三区四| 国产女高清在线看免费观看| 精品国产亚洲区久久露脸| 国产精品色热综合在线| 亚洲国产精品久久综合网| 福利新区一区二区人口| 久久一区内射污污内射亚洲| 亚洲精品伦理熟女国产一区二区| 成人精品一区二区三区在线| 国产三级黄片在线免费看| 国产中文字幕久久黄色片| 男女午夜视频在线观看免费| 超薄丝袜足一区二区三区| 中文字幕高清不卡一区| 日韩人妻一区二区欧美| 好吊妞视频免费在线观看| 亚洲一区二区三区精选| 欧美一区二区三区高潮菊竹| 少妇在线一区二区三区| 深夜福利亚洲高清性感| 91熟女大屁股偷偷对白| 不卡一区二区高清视频| 欧美熟妇喷浆一区二区| 日韩中文字幕狠狠人妻| 欧美日韩国产综合特黄| 人妻一区二区三区多毛女| 人人妻在人人看人人澡| 日本一本在线免费福利| 欧美性高清一区二区三区视频| 日韩一区二区三区在线欧洲| 一二区中文字幕在线观看| 黄色国产精品一区二区三区| 99久久国产精品成人观看 | 中文字幕免费观看亚洲视频| 久久永久免费一区二区| 日本高清中文精品在线不卡| 久久精品久久精品中文字幕| 日本婷婷色大香蕉视频在线观看 | 亚洲精品高清国产一线久久|