123.JPG

 

 

因為偶爾會寫記綠code,所以特別找了美化的部分

找了好久才找到想要的,所以記錄下來

 

首先在樣式管理的css當中加入一段代碼

.myCODE {
    display: block; /* fixes a strange ie margin bug */
    font-family: Courier New;
    font-size: 8pt;
    overflow:scroll;
    background: #f0f0f0 url(http://klcintw.images.googlepages.com/Code_BG.gif) left top repeat-y;
    border: 1px solid #ccc;
    padding: 10px 10px 10px 21px;
    max-height:200px;
    line-height: 1.2em;
}

 

然後在寫文章時,將加入已下代碼

 

<pre class = 'myCODE'>
代碼
</pre>

 

就可以顯示成像一開始的圖片一樣囉 :)

 

 

 
arrow
arrow
    全站熱搜

    Chia 發表在 痞客邦 留言(0) 人氣()