Category Archives: 程式設計

[Linux] The useage of ioctl function: some materials

This post is to note some materials for Linux ioctl function: ioctl: hdio Linux kernel map: Chapter 6.1 ioctl Linux Device Driver 專欄 Linux 驅動程式的 I/O, #1: 基本概念 Linux 驅動程式的 I/O, #3: kernel-space 與 user-space 的「I/O」 Linux 驅動程式的 I/O, #4: … Continue reading

Posted in C/C++, Linux, Programming, 程式設計 | 1 Comment

[PHP] MySQL Backup by GMail

[Chinese]        先前已經介紹過有一個好用的MySQL資料庫備份工具(使用PHP):MySQLDump。但是預設的寄信函式,是透過SMTP伺服器寄信,這對於沒有SMTP伺服器的使用者而言,可就傷腦筋了。原先我有找到一篇教學,使用GMail的SMTP伺服器做備份,可惜連結已經失效了。筆者只好自行撰寫,由於程式碼使用GPL授權,基於分享的精神下,便公開給各位。         程式碼下載處:請按我。 [English]I’ve introduced an useful backup tool for backuping MySQL databases (using PHP): MySQLDump. However,the default send mail function uses the SMTP server to send mails, and it may cause some problems … Continue reading

Posted in PHP, Programming, Web Design, 科技, 程式設計, 軟體(Software) | Leave a comment

[PHP] The resources about calling windows programs in PHP

I’ve developed  one library about security and make as a .dll package. Now, I want to use the dll through PHP because my significant webdesign skill is PHP, not ASP.Net. The other reason is that I don’t prefer to install two different … Continue reading

Posted in PHP, Programming, Windows, 程式設計 | Leave a comment

[Hadoop] Hadoop 安裝與國網中心Hadoop實作

在中部某科大上課,教到Hadoop,就把一些教材更正的釋出。Hadoop單機安裝這份跟國網中心提供的單機安裝教學有些不同,差異性在於Hadoop 0.22.x啟動方法跟如何安裝JDK 1.7。請點此觀看在國家高速網路中心Hadoop下實作教到如何在國家高速網路中心上使用Hadoop叢集,順便把這一份教材釋出。 請點此觀看

Posted in cloud computing, hadoop, Java, 程式設計 | Leave a comment

[PHP] Solution for the Message in PHPMyAdmin: Query was empty!

During the few days, I’ve encountered a problem for operating PHPMyadmin at my workstation. It is very strange situation while  clicking the viewing button in PHPMyadmin. Whenever I click the viewing button, the result is always the shown message with … Continue reading

Posted in PHP, 程式設計, 網頁撰寫 | Leave a comment

[PHP] 幸運輪盤點名系統

這學期為了教課,班上人數有60人。一個一個點又太麻煩,想說用抽點的。寫個程式來幫助我產生抽點名單。:)首先,準備MySQL資料庫與一張資料表,以這個範例來說,我有張student的資料表,schema如下: 資料表:student 欄位名稱  資料類型 描述 no VARCHAR(10) 學生學號 name VARCHAR(60) 學生姓名 準備我要的資料庫設定檔: 準備好資料庫連線Class: 準備好點名程式: 上述東西準備好後,就可以開始點名了。:P備註:我好像吃飽太閒! =.=

Posted in PHP, 程式設計 | Leave a comment

[Google Extension] Yahoo字典查詢器

為了學英文,有點不爽Google開發的Google Dictionary。花了一些時間,自己研究怎麼寫一個簡易的查字典工具。最後終於完成啦! 下載網址:請按我。

Posted in 程式設計, 資工, 雲端運算 | 2 Comments

[PHP] INI設定與Debug教學

在DoubleService的教學中提及,在開發PHP測試函式庫時,由於各個伺服器對於php.ini的設定可能都不一樣。因此,在測試函式庫之前,最好加入以下幾行,以確保自己的程式正確無虞。 有了上述的程式碼,就可以輕鬆Debug囉。另外,請記得在將程式碼交給客戶之前,把Debug模式關閉喔。至於為什麼要通過這些檢查呢?DobuleService曾經提及: 1. 避免變數名前後不小心打錯。2. 避免不存在的鍵值,隱藏可能的邏輯錯誤。3. 強制變數初始化,避免變數交互引用覆蓋或誤用。4. 強制正規化變數型態,避免隱藏性錯誤。5. 自然養成嚴謹的編程習慣。6. 強化程式本身的環境可攜性。 另外,值得一提的是,並非所有ini設定都可以透過ini_set()這個函式來設定的,只有被系統規範為PHP_INI_ALL或是 PHP_INI_USER的選項,才可以使用ini_set()。若不清楚哪些可設定的話,請參見twphp提供的資料:http://tw.php.net/manual/en/ini.list.php 參考資料 開發PHP時可能會做的環境設定 PHP開發開啟E_ALL的重要性 List of php.ini directives PHP:ini_set()可更改的項目 Why is the result of E_ALL | E_STRICT the same as only E_ALL? php.ini開啟error設定

Posted in PHP, 程式設計, 網頁撰寫 | Leave a comment

[PHP] PEAR、MVC、ZendFramework相關教學資源

PEAR 教學資源 Testing PHP Code with PHPUnit Caching PHP Programs with PEAR [Web] 連結分享 Package Information: XML_Parser Generating Code from Tests PEAR:AUTH的用法1 Package Information: HTML_QuickForm2 Package Information: Pager Package Information:HTML_TreeMenu [PHP] 好用的 PEAR – PHP Mail and Mail_Mime 安裝與使用PhpDocumentor [PHP]用PEAR::SOAP寫個簡單的WebService … Continue reading

Posted in PHP, 程式設計, 網頁撰寫, 資訊安全 | Leave a comment

【Chrome】Chrome Extension與App開發

In short, Chrome extension(or app.) application is composed of different html, javascript, and css files. It is very simple to develop. Basically, you can consider it as a normal client-server implementation.To record some materials that I can develop my Chrome … Continue reading

Posted in browser, cloud computing, jQuery, 程式設計, 網頁撰寫, 雲端運算 | Leave a comment