How to configure php? Sessions & mysql support
Hi all! I have just installed SuSE 9.3 and Apache 2 with php 4.3.10 and mysql I noticed a problem with one of the sites my linux box serves up: the problem seems to have to do with sessions. Here is a snip from phpinfo() Configure Command './configure' '--prefix=/usr' '--datadir=/usr/share/php' '--mandir=/usr/share/man' '--bindir=/usr/bin' '--libdir=/usr/share' '--includedir=/usr/include' '--sysconfdir=/etc' '--with-_lib=lib' '--with-config-file-path=/etc' '--with-exec-dir=/usr/lib/php/bin' '--disable-debug' '--enable-inline-optimization' '--enable-memory-limit' '--enable-magic-quotes' '--enable-safe-mode' '--enable-sigchild' '--disable-ctype' '--disable-session' '--without-mysql' '--disable-cli' '--without-pear' '--with-openssl' '--with-apxs2=/usr/sbin/apxs2-prefork' 'i586-suse-linux' Notice the '--disable-session' and also '--without-mysql' How do I change this? I have installed this through YAST. Here is a snip from phpinfo() on my old box where the website is running fine (php 4.3.3): Configure Command './configure' '--prefix=/usr/share' '--datadir=/usr/share/php' '--bindir=/usr/bin' '--libdir=/usr/share' '--includedir=/usr/include' '--sysconfdir=/etc' '--with-_lib=lib' '--with-config-file-path=/etc' '--with-exec-dir=/usr/lib/php/bin' '--disable-debug' '--enable-bcmath' '--enable-calendar' '--enable-ctype' '--enable-dbase' '--enable-discard-path' '--enable-exif' '--enable-filepro' '--enable-force-cgi-redirect' '--enable-ftp' '--enable-gd-imgstrttf' '--enable-gd-native-ttf' '--enable-inline-optimization' '--enable-magic-quotes' '--enable-mbstr-enc-trans' '--enable-mbstring' '--enable-mbregex' '--enable-memory-limit' '--enable-safe-mode' '--enable-shmop' '--enable-sigchild' '--enable-sysvsem' '--enable-sysvshm' '--enable-track-vars' '--enable-trans-sid' '--enable-versioning' '--enable-wddx' '--enable-yp' '--with-bz2' '--with-dom=/usr/include/libxml2' '--with-ftp' '--with-gdbm' '--with-gettext' '--with-gmp' '--with-imap=yes' '--with-iodbc' '--with-jpeg-dir=/usr' '--with-ldap=yes' '--with-mcal=/usr' '--with-mcrypt' '--with-mhash' '--with-mysql=/usr' '--with-ndbm' '--with-pgsql=/usr' '--with-png-dir=/usr' '--with-readline' '--with-snmp' '--with-t1lib' '--with-tiff-dir=/usr' '--with-ttf' '--with-freetype-dir=yes' '--with-xml' '--with-xpm-dir=/usr/X11R6' '--with-zlib=yes' '--with-qtdom=/usr/lib/qt3' '--with-gd' '--with-openssl' '--with-curl' '--with-swf=/usr/src/packages/BUILD/swf/dist/' '--with-imap-ssl' '--enable-xslt' '--with-xslt-sablot' '--with-iconv' '--with-mm' '--with-apxs=/usr/sbin/apxs' 'i586-suse-linux' Is there anything else that I should enable/disable while I am at it? Regards from Denmark. Dan
On Tuesday 04 October 2005 06:23, DanTheMan wrote:
Hi all!
I have just installed SuSE 9.3 and Apache 2 with php 4.3.10 and mysql
I noticed a problem with one of the sites my linux box serves up: the problem seems to have to do with sessions.
Here is a snip from phpinfo()
Configure Command './configure' '--prefix=/usr' '--datadir=/usr/share/php' '--mandir=/usr/share/man' '--bindir=/usr/bin' '--libdir=/usr/share' '--includedir=/usr/include' '--sysconfdir=/etc' '--with-_lib=lib' '--with-config-file-path=/etc' '--with-exec-dir=/usr/lib/php/bin' '--disable-debug' '--enable-inline-optimization' '--enable-memory-limit' '--enable-magic-quotes' '--enable-safe-mode' '--enable-sigchild' '--disable-ctype' '--disable-session' '--without-mysql' '--disable-cli' '--without-pear' '--with-openssl' '--with-apxs2=/usr/sbin/apxs2-prefork' 'i586-suse-linux'
Notice the '--disable-session' and also '--without-mysql'
How do I change this? I have installed this through YAST.
Here is a snip from phpinfo() on my old box where the website is running fine (php 4.3.3): Configure Command './configure' '--prefix=/usr/share' '--datadir=/usr/share/php' '--bindir=/usr/bin' '--libdir=/usr/share' '--includedir=/usr/include' '--sysconfdir=/etc' '--with-_lib=lib' '--with-config-file-path=/etc' '--with-exec-dir=/usr/lib/php/bin' '--disable-debug' '--enable-bcmath' '--enable-calendar' '--enable-ctype' '--enable-dbase' '--enable-discard-path' '--enable-exif' '--enable-filepro' '--enable-force-cgi-redirect' '--enable-ftp' '--enable-gd-imgstrttf' '--enable-gd-native-ttf' '--enable-inline-optimization' '--enable-magic-quotes' '--enable-mbstr-enc-trans' '--enable-mbstring' '--enable-mbregex' '--enable-memory-limit' '--enable-safe-mode' '--enable-shmop' '--enable-sigchild' '--enable-sysvsem' '--enable-sysvshm' '--enable-track-vars' '--enable-trans-sid' '--enable-versioning' '--enable-wddx' '--enable-yp' '--with-bz2' '--with-dom=/usr/include/libxml2' '--with-ftp' '--with-gdbm' '--with-gettext' '--with-gmp' '--with-imap=yes' '--with-iodbc' '--with-jpeg-dir=/usr' '--with-ldap=yes' '--with-mcal=/usr' '--with-mcrypt' '--with-mhash' '--with-mysql=/usr' '--with-ndbm' '--with-pgsql=/usr' '--with-png-dir=/usr' '--with-readline' '--with-snmp' '--with-t1lib' '--with-tiff-dir=/usr' '--with-ttf' '--with-freetype-dir=yes' '--with-xml' '--with-xpm-dir=/usr/X11R6' '--with-zlib=yes' '--with-qtdom=/usr/lib/qt3' '--with-gd' '--with-openssl' '--with-curl' '--with-swf=/usr/src/packages/BUILD/swf/dist/' '--with-imap-ssl' '--enable-xslt' '--with-xslt-sablot' '--with-iconv' '--with-mm' '--with-apxs=/usr/sbin/apxs' 'i586-suse-linux'
Is there anything else that I should enable/disable while I am at it?
Regards from Denmark.
Dan
Check that all the necessary php packages are installed, in particular php-session and php-mysql. Most of the php packages do not get installed by default. In my experience, you have to install almost all of them. Also make sure that you have an .htaccess file in the document root of each server/virtual server # php variables php_value session.name jjhhw php_value register_globals 0 php_value session.use_cookies 1 php_value session.save_path /tmp php_value session.auto_start 1 php_value session.bug_compat_warn 0 Peter
participants (2)
-
DanTheMan
-
Peter Sutter