5. Install PHP

Download the latest PHP distribution and unpack it.

Change to the php directory and run the configure script. You need to pass certains options to the script. To enable PHP access Sybase, you need --with-sybase-ct. You will also need to specify the web server interface to use; in our case, this is Apache, so we use --with-apache To build a CGI version of PHP, (which is also very useful as a shell scripting tool), just leave out the --with-apache.

Here is a complete configure script with the above two options, as well as a number of other options that are useful.

    # ./configure --with-apache=../apache_1.3.19
      --with-sybase-ct=/opt/sybase --enable-bcmath --enable-calendar
      --enable-ctype --enable-exif --enable-ftp --enable-gd-imgstrttf
      --with-gd --enable-trans-sid --enable-shmop --enable-sockets
      --enable-sysvsem --enable-sysvshm --enable-wddx

You will need to change to apache path to wherever you unpacked your apache distribution.

If the configure scripts completes successfully, you can then proceed:

    # make && make install

PHP should compile without any hitches. After it has installed, you need to install the php.ini file:

    # cp php.ini-optimized /usr/local/lib/php.ini

Now we need to change a few things in /usr/local/lib/php.ini. Set the following parameters to the ones specified below:

    magic_quotes_sybase = on
    sybct.min_server_severity = 11
    sybct.min_client_severity = 11

I also like to set the following:

    register_globals = on
    include_path=.:/usr/local/lib/php

You have now completed the PHP installation.

Hosting by: Hurra Communications Ltd.
Generated: 2007-01-26 17:57:56