目前分類:Blog語法 (4)

瀏覽方式: 標題列表 簡短摘要

Online syntax highlighting

線上直接輸入code後選擇想要表示的語言便會自動幫我們轉換成適合blog用的HTML

 

以下為測試結果

1. eclipse呈現

import java.sql.Connection;
import java.sql.DriverManager;

public class JDBC1 {

    
    
    public static void main(String[] args) {
        System.out.println("開始要連囉");
        try {
            Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
            System.out.println("Loading JDBC-ODBC driver sucess.");

            Connection con = DriverManager.getConnection("jdbc:odbc:john", "","");
            System.out.println("connecting to data base sucess.");
            con.close();
        } catch (Exception e) {
            System.out.println("Loading JDBC-ODBC driver error.");
        }

    }
}

 

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

除了上述的方式比較適合痞子邦(有支援情況)

google這種方式可用在其它的blog上唷

且還幫忙做好好的真是省事呢


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

 

這個方式在痞子邦適用...或者可以說目前站方僅釋出支援到此

 

 

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

code {
display: block; /* fixes a strange ie margin bug */
font-family: Courier New;
font-size: 8pt;
overflow:auto;

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