Markdown 博客撰写常用代码段
1、控制图片大小
不居中
<img src="./xxx.png" width = "300" height = "200" alt="图片名称"/>
居中
<div align="center">
<img src="./xxx.png" width = "300" height = "200" alt="图片名称"/>
</div>
2、版权衔接线
---
<div align=right>^^ 版权衔接线 vv     <a href="http://www.cnblogs.com/tangyikejun/p/4361638.html" >全文出处:http://www.cnblogs.com/tangyikejun/p/4361638.html </a></div>
---
3、添加目录视图
用以下代码包裹
<ul id="tree" class="ztree"></ul>
<article class='markdown-body'>
...
</article>
<script type="text/javascript" src="http://i5ting.github.io/git-quick-start/preview/js/jquery-1.10.2.min.js"></script>
<script type="text/javascript" src="http://i5ting.github.io/git-quick-start/preview/js/jquery.ztree.all-3.5.min.js"></script>
<script type="text/javascript" src="http://i5ting.github.io/git-quick-start/preview/js/jquery.ztree_toc.js"></script>
<SCRIPT type="text/javascript" >
<!--
$(document).ready(function(){
$('#tree').ztree_toc({
documment_selector:'.markdown-body',
ztreeStyle: {
width:'260px',
overflow: 'auto',
'z-index': 2147483647,
border: '0px none',
left: '0px',
top: '0px'
}
});
});
</SCRIPT>