Jeans & Development:
Deprecated: Function strftime() is deprecated in /home/u109394186/domains/rad51.net/public_html/jeans/jeans/libs/blog.php on line 333
2006年 03月の記事

SQLite-6 [Nucleus/SQLite]

2006年3月10日

MySQLでの文字列のエスケープの仕方に関する記述はここに
 これによると、『¥』を用いたエスケープ以外に、

‘'’ で囲んだ文字列内で ‘'’ を使用する場合、文字列内の ‘'’ は '''' と記述することができる。

‘"’ で囲んだ文字列内で ‘"’ を使用する場合、文字列内の ‘"’ は '""' と記述することができる。

ということらしい。このあたりもSQLite用のラッパーで反映させておかないと、上手くいかないケースもあるかも知れない。
(対応済み)

SQLite-5 [Nucleus/SQLite]

2006年3月9日

次なる問題は、クエリーでの

SHOW FIELDS FROM (→完了)
SHOW KEYS FROM (→完了)
SHOW TABLES LIKE (→完了)
DROP TABLE IF EXISTS (→完了)

これらが、データベースのバックアップ時に必要。
(追記)
DROP TABLE IF EXISTS は解決。結果として、データベースの取り込みはできるようになった模様。書き出しには、SHOW FIELDS FROM と SHOW KEYS FROM が必要(→完了)。

SQLite-4 [Nucleus/SQLite]

2006年3月8日

 Nucleus 3.22 en/ja を、SQLite用に自動変換するスクリプト。ほぼできあがったので、ここにメモ。

SQLite-3 [Nucleus/SQLite]

2006年3月7日

Nucleus SQLite化計画の現在の進行状況。

SQLite-2 [Nucleus]

2006年3月6日

NucleusでSQLiteを使用するためのラッパー。
とりあえず、ブログが表示できるようになったので、メモ。

SQLite [Nucleus/SQLite]

2006年3月4日

 SQLiteとMySQLの文法の違いを比較してみた。

Nucleus プラグインのテンプレート [Nucleus]

2006年3月2日

ここから始めようという、テンプレート。
<?php 
class NP_Template extends NucleusPlugin { 
    function getName() { return preg_replace('/^.*[\/\\\\]NP_([^\/\\\\]*)\.php$/','$1',__FILE__); }
    function getMinNucleusVersion() { return 220; }
    function getAuthor()  { return 'Katsumi'; }
    function getVersion() { return '0.1'; }
    function getURL() {return 'http://hp.vector.co.jp/authors/VA016157/';}
    function getDescription() { return $this->getName().' plugin'; } 
    function supportsFeature($what) { return (int)($what=='SqlTablePrefix'); }
    function getEventList() { return array(); }
    //function getTableList() { return $this->sql_query('list'); }
    function install() {/* $this->sql_query('create','(id int(11) not null auto_increment)'); */}
    function unInstall() {/* $this->sql_query('drop'); */}
    //function init() {}
    //function doSkinVar($skinType,$type) {}
    //function doTemplateVar(&$item,$type) {}
    //function doAction($type){}
    /* function sql_query($mode='name',$p1=''){
        $tablename[0]=sql_table(strtolower('plugin_'.substr(get_class($this),3)));
        switch($mode){
        case 'create': return sql_query('CREATE TABLE IF NOT EXISTS '.$tablename[0].' '.$p1);
        case 'drop':   return sql_query('DROP TABLE IF EXISTS '.$tablename[0]);
        case 'list':   return $tablename;
        case 'name':   return $tablename[0];
        default:       return sql_query($mode.' '.$tablename[0].' '.$p1);
        }
    } */
    function getOption($name){ return $this->_getOption('global', 0, $name); }//required for Nucleus 3.24
}
?>

PHPで`If-Modified-Since`をチェックする [プログラミング]

2006年3月1日

 "HTTP/1.1 304 Not Modified"で返す際の判定ルーチン。NP_MediaFiles用のthumbnail.phpで使用しようと製作したが、速度の向上が認められず削除。製作したルーチンは簡潔で、しかもうまく働いていただけに、捨てるには忍びずここにメモすることにした。
   後の記事>>