2010-12-21

Regular Expression 測試 2 (Regular Expression Test 2)

只利用 Regex 來測試字串是否符合 IPv4 格式



共 158 個字元

2010-12-19

Regular Expression 測試 1 (Regular Expression Test 1)

只利用 Regex 來測試字串是否符合24小時制時間格式



共 80 個字元

2010-11-27

更改 Ubuntu 的 Button Layout (Modify button layout in Ubuntu)

Ubuntu10.04+ 的按鈕排放在左邊,變成與 Mac OS 相似的設定
這種設定使部分習慣使用 Windows 或各種 Linux (安裝 X Window System) 的用家或多或少構成不便
Ubuntu 允許使用者更改按鈕的擺放位置
The button layout move to the left side in Ubuntu10.04+, like Mac OS
This settings inconvenience the tranditional user of Windows or Linux (install with X Window System)
Ubuntu allow user to modify the button layout

PHP UTF-8 編碼與 session 及 header 問題 (Solving BOM of UTF-8 File Encoding problem with PHP session and header)

網絡上不少跨語言網頁大部分都是以 UTF-8 作為編碼
但利用 UTF-8 編碼編寫 PHP 文件使用到 session 及 header 時便會發生問題
UTF-8 編碼的文件會在文件檔頭加上 3個bytes 的資料,這 3個bytes 稱為 BOM - Byte Order Mark
在標準制式下 UTF-8 的這 3個bytes 分別是:
第一個byte - 0xef
第二個byte - 0xbb
第三個byte - 0xbf
UTF-8 is a popular File Encoding on the internet.
However, when we use UTF-8 with PHP using session and header there are some error occurs.
UTF-8 file has 3 bytes of data at the beginning of file, this 3 bytes called BOM - Byte Order Mark
The standard of UTF-8 file of this 3 bytes is:
1st byte - 0xef
2nd byte - 0xbb
3rd byte - 0xbf

2010-11-17

Windows VISTA / Windows 7 不能使用 VBScript 的 CommanDialog (VBScript CommonDialog in Windows VISTA and Windows 7)

不少人在 Windows 處理簡單的程序時,往往會用到 VBScript
而使用 VBScript 涉及檔案存取時不少人都會想到使用 File Dialog 讓使用者有一個具 GUI 的檔案選擇工具
VBScript is a light, useful programming language (script) in Windows OS
We can write a VBS with notepad or any text editor
We always select a file with File Dialog
File Dialog is a user-friendly GUI for user to select a specific file

2010-10-18

利用 PEAR 製作 Excel 檔案 (Use PEAR to create an Excel file)

PEAR 為 PHP Extension and Application Repository 的簡稱
是一種以 PHP 物件導向的設計的程式庫
PEAR is the abbreviation of PHP Extension and Application Repository

2010-10-11

Bio Hazard Remake / Resident Evil Remake Chris Invisible Enemy Hard

Bio Hazard / Resident Evil Remake Chris Invisible Enemy Hard Part 01

Bio Hazard Remake / Resident Evil Remake Chris Real Survival

Bio Hazard / Resident Evil Remake Chris Real Survival Part 01

Bio Hazard Remake / Resident Evil Remake Chris New Game

Bio Hazard / Resident Evil Remake Chris New Game Part 01

Bio Hazard Remake / Resident Evil Remake Jill Invisible Enemy Hard

Bio Hazard / Resident Evil Remake Jill Invisible Enemy Hard Part 01

Bio Hazard Remake / Resident Evil Remake Jill Real Survival

Bio Hazard / Resident Evil Remake Jill Real Survival Part 01

Bio Hazard Remake / Resident Evil Remake Jill New Game

Bio Hazard / Resident Evil Remake Jill New Game Part 01

Bio Hazard Zero (Ø) / Resident Evil Zero (Ø) Hard

Bio Hazard / Resident Evil Zero Hard Part 01

Bio Hazard Zero (Ø) / Resident Evil Zero (Ø)

Bio Hazard / Resident Evil Zero Part 01

Bio Hazard Outbreak File 2 / Resident Evil Outbreak File 2 Extra Series

Bio Hazard / Resident Evil Outbreak File 2 Elimination 1 Very Hard Nightmare Part 1

Bio Hazard Outbreak File 2 / Resident Evil Outbreak File 2 Very Hard Series

Bio Hazard / Resident Evil Outbreak File 2 Stage 1 Very Hard Part 1

Bio Hazard Outbreak File 2 / Resident Evil Outbreak File 2 Hard Series

Bio Hazard / Resident Evil Outbreak File 2 Stage 1 Hard Part 1

Bio Hazard Outbreak File 2 / Resident Evil Outbreak File 2 Normal Series

Bio Hazard / Resident Evil Outbreak File 2 Stage 1 Normal Part 1

Bio Hazard Outbreak / Resident Evil Outbreak Very Hard Series

Bio Hazard / Resident Evil Outbreak Stage 1 Very Hard Part 1

Bio Hazard 4 / Resident Evil 4 The Another Order / Separate Ways

Bio Hazard / Resident Evil 4 The Another Order / Separate Ways 01