入口
pkgsrc による設置
  php3
    php3-i18n
    database/php3-pgsql
    www/ap-php3
apache 版
postgres (1)
  php4-pgsql (3)
    make install
php4 (apache1)
  www/php4(2)
    php4 の版
  www/ap-php4(5)
  www/apache(4)
    IPv6
    IPv4+nossl
    Apache/SSL
php4(apache2) - 依存関係
  ap2-php4
    php4
    mod_php4.so
    /usr/pkg/etc/php.ini
  php4-session(6)
    session.so
    --enable-session
    core_globals
    map
    php4 i18n 無
    php4 i18n
  configure
セッション管理
  php3 互換モード
  php4 内蔵
  php4 + phplib
  phpinfo()
PostgreSQL 準備
  postmaster
  環境変数
  initdb
    実際の様子
    試しに起動
  postmaster 設定
  postgreql.conf
  pg_hba.conf
  postmaster の起動
  使用者登録
  pg_ctl
  /etc/rc.conf
  shutdown
データべースを作る
psql
  psql \h
  psql \?
  psql \h select
  psql \d
  psql \copy
  psql 操作
  Data Type
    DATE
Application
  pgpost
    pgpost 設置例
    psql で見る
  AuthPG
      create table
        GRANT
  pgimage
  pgimage psql
SQL
URL
  PostgreSQL
  PHP
良くある問題
    undefined pg_connect()
    Link-ID == false
    Call-time pass-by-reference
    session_register
    Undefined session_adapt_flush
    Failed opening for inclusion
  does not exist in ..
  pg_exec() query failed
  Undefined property: Port
  undefined function: preg_match()
  used in non-rule query
その他
適用例
  日記から等

PostgreSQL + Apache + PHP4 | PHP4 programming

php4 i18n 無

これは多分だめな例

php version-4.1.2 + info.php

configure command の欄が

'./configure' '--without-mysql' '--without-pcre-regex' '--disable-posix' '--disable-session' '--disable-xml' '--with-config-file-path=/usr/pkg/etc' '--with-exec-dir=/usr/pkg/libexec/php4' '--with-regex=system' '--enable-discard-path' '--enable-force-cgi-redirect' '--enable-memory-limit' '--enable-track-vars' '--with-apxs=/export/pkgsrc/www/ap-php4/work/.buildlink/sbin/apxs' '--host=powerpc--netbsd' '--prefix=/usr/pkg'
となっていて、 www/php4 のところで指定した
--enable-i18n --enable-mbstring --enable-mbstr-enc-trans 
が表示されていなくて、代りに
 --with-apxs=/export/pkgsrc/www/ap-php4/work/.buildlink/sbin/apxs
の文字が入っている。次の時に取替えられているのかな。
=> Checksum OK for php-4.1.2.tar.gz.
===> Extracting for ap-php-4.1.2
===> Required installed package php>=4.1.2: php-4.1.2 found
===> Required installed package apache{,6}-1.3.*: apache6-1.3.22nb1 found
===> Required installed package perl>=5.0: perl-5.6.1nb6 found
===> Required installed package apache{,6}-1.3.*: apache6-1.3.22nb1 found
===> Required installed package libtool-base>=1.4.20010614nb4: libtool-base-1.4.20010614nb4 found
===> Patching for ap-php-4.1.2
===> Applying NetBSD patches for ap-php-4.1.2
===> Configuring for ap-php-4.1.2
=> Linking apache files into /export/pkgsrc/www/ap-php4/work/.buildlink.
=> Creating script /export/pkgsrc/www/ap-php4/work/.buildlink/sbin/apxs.
creating cache ./config.cache
checking for a BSD compatible install... /usr/bin/install -c -o root -g wheel
www/ap-php4 の Makefile にも、
CONFIGURE_ARGS+= --enable-i18n --enable-mbstring --enable-mbstr-enc-trans 
を加えることで、一応解決するように見える。

(20041206)
実際には Makefile.php が双方から参照されているので、次の変更だけでよい。

RCS file: /e/owada/cvsync/pkgsrc/www/php4/Makefile.php,v
retrieving revision 1.19
diff -u -r1.19 Makefile.php
--- Makefile.php        27 Nov 2004 14:00:08 -0000      1.19
+++ Makefile.php        6 Dec 2004 06:20:41 -0000
@@ -21,6 +21,7 @@
 CONFIGURE_ARGS+=       --with-regex=system
 
 CONFIGURE_ARGS+=       --enable-discard-path
+CONFIGURE_ARGS+=       --enable-i18n --enable-mbstring --enable-mbstr-enc-trans 
 CONFIGURE_ARGS+=       --enable-force-cgi-redirect
 CONFIGURE_ARGS+=       --enable-memory-limit
 CONFIGURE_ARGS+=       --enable-track-vars
ただし変更した後に www/php4 と www/ap-php で
make clean && make && make install
する必要がある。そうしておいて、 /usr/pkg/etc/php.ini を、次のように変更する。
--- /usr/pkg/etc/php.ini-original	2004-12-06 14:09:28.000000000 +0900
+++ /usr/pkg/etc/php.ini	2004-12-06 15:17:28.000000000 +0900
@@ -116,7 +116,7 @@
 ;       is doing.
 ; Note: You cannot use both "mb_output_handler" with "ob_iconv_handler"
 ;       and you cannot use both "ob_gzhandler" and "zlib.output_compression". 
-;output_handler =
+output_handler = mb_output_handler
 
 ; Transparent output compression using the zlib library
 ; Valid values for this option are 'off', 'on', or a specific buffer size
@@ -1044,14 +1044,14 @@
 ; internal/script encoding.
 ; Some encoding cannot work as internal encoding.
 ; (e.g. SJIS, BIG5, ISO-2022-*)
-;mbstring.internal_encoding = EUC-JP
+mbstring.internal_encoding = EUC-JP
 
 ; http input encoding.
 ;mbstring.http_input = auto
 
 ; http output encoding. mb_output_handler must be
 ; registered as output buffer to function
-;mbstring.http_output = SJIS
+mbstring.http_output = EUC-JP
 
 ; enable automatic encoding translation accoding to 
 ; mbstring.internal_encoding setting. Input chars are

この画面は Jeedosaquin によって表示しています。
Last Update: Sat, 04 May 2019 00:45:20 GMT 1.66 2008/03/08