�o�g�峹�b�y�z���[�] PttBlog, �̫᪺�s�פΪ����O: $Id$ �Ъ`�N, PttBlog���ӥD�n�O�]�p�� Ptt2 ���x�ϥ�, �ثe���b�}�o���q, �å������Y�K������, �i���ٯʤ֫ܦh�\��, �H�Υi��\�h�� bug. �z�i�H���ӤU�C���B�J�w�˦n PttBlog. 1.�w�˦n�U�C���F��, �ڭ̨æP�ɦC�W FreeBSD ports�����ؿ�: apache /usr/ports/www/apache13/ perl /usr/ports/lang/perl5.8/ mod_perl /usr/ports/www/mod_perl/ mysql /usr/ports/databases/mysql323-server/ �H�ΤU�C�� module Template /usr/ports/www/p5-Template-Toolkit/ Date::Calc /usr/ports/devel/p5-Date-Calc/ DBI /usr/ports/databases/p5-DBI/ DBD::mysql /usr/ports/databases/p5-DBD-mysql/ MD5 /usr/ports/security/p5-MD5/ Mail::Sender /usr/ports/mail/p5-Mail-Sender/ OurNet::FuzzyIndex (�٨S���i ports, �Х� cpan ��) 2.�]�w apache �i�H�����z�L mod_perl �Ӷ] perl script . �b�z�� apache.conf (or httpd.conf)��, ���ӷ|��: LoadModule perl_module libexec/apache/libperl.so AddModule mod_perl.c �b<IfModule mod_mime.c></IfModule>����, �[�W�o���: AddHandler perl-script .pl PerlHandler Apache::Registry 3.�]�w�n blog �� web�ؿ�. �̭��ܤ֭n�� index.pl, blog.pl, LocalVars.pm (�䤤 LocalVars.pm ��ij�� symbolic link �� /home/bbs/bin/�����@��) �䤤 *.pl ���v���n�O�i�H���檺 (ex: chmod 755 *.pl) 4.�]�w apache ���� blog ���ؿ�. �ñN�ӥؿ��}�l ExecCGI�� option. �Ҧp�ϥ� Virtual Host : NameVirtualHost * <VirtualHost *> ServerName blog.ptt2.cc DocumentRoot /home/bbs/blog/web <Directory "/home/bbs/blog/web"> Options ExecCGI </Directory> </VirtualHost> 5.�N builddb.pl, BBSFileHeader.pm �����i ~bbs/bin �z�i�H���ե� perl -c ~bbs/bin/builddb.pl ���լݬݯण��L. �Y���檺��, �q�`�O LocalVars.pm �̭��֪F��, �аѦ� pttbbs/sample/LocalVars.pm �� blog ��. 6.�Ѧ� pttbbs/sample/pttbbs.conf��, �b�z�� pttbbs.conf���[�J BLOGDB_HOST, BLOGDB_USER, BLOGDB_PASSWD, BLOGDB_DB, BLOGDB_PORT, BLOGDB_SOCK �åB���s compile mbbsd, �b make �ɥ[�J WITH_BLOG=yes . �M�� install �åB restart 7.���� Mysql�@���n�U����� table (�i�H�����ƻs�L�h�]) CREATE TABLE `comment` ( `brdname` varchar(13) NOT NULL default '', `artid` int(11) NOT NULL default '0', `name` varchar(32) NOT NULL default '', `mail` varchar(64) NOT NULL default '', `content` text NOT NULL, `mtime` int(11) NOT NULL default '0', `hash` varchar(32) NOT NULL default '' ) TYPE=MyISAM; CREATE TABLE `counter` ( `k` char(32) NOT NULL default '', `v` int(11) NOT NULL default '0', `mtime` int(11) NOT NULL default '0', PRIMARY KEY (`k`) ) TYPE=MyISAM; CREATE TABLE `wcounter` ( `k` char(32) NOT NULL default '', `v` int(11) NOT NULL default '0', `mtime` int(11) NOT NULL default '0', PRIMARY KEY (`k`) ) TYPE=MyISAM;