很簡單,首先我們需要下載在 Linux 下 MSSQL 支援 Freetds 下載安裝后,在PHP安裝源文件夾里重新編譯(compile)后安裝即可
-------------------------------------------
# wget http://ibiblio.org/pub/Linux/ALPHA/freetds/stable/freetds-stable.tgz
-
# tar zxvf freetds-stable.tgz
# cd freetds-stable.tgz
# ./configure --prefix=/usr/local/freetd
# make
# make install
進入PHP安裝原文件夾
php5.2.5
./configure \-prefix=/usr/local/php \
-with-apxs2=/usr/local/apache/bin/apxs \
-with-mysql=/usr/local/mysql \
-with-mysqli=路徑 \
-with-mssql=/usr/local/freetd \
-with-freetype-dir \
-with-zlib-dir \
-with-jpeg-dir \
-with-png-dir \
-with-gd \
-with-config-file-path=/usr/local/lib \
-with-libxml-dir=/usr/lib \
-enable-ftp \
-enable-safe-mode \
-disable-debug
make
make install
cp php.ini-dist /usr/local/lib/php.ini 本文出自:億恩科技【1tcdy.com】
服務器租用/服務器托管中國五強!虛擬主機域名注冊頂級提供商!15年品質保障!--億恩科技[ENKJ.COM]
|