Re: [PHP-DB] mysql_connect problem rh7.3
Thanks! I was able to get native mysql support by adding extension=mysql.so to php.ini. So now mysql_connect() works John Coder wrote: While Micah is correct, you do have mysql support on php but as a dbs not the built in php fuctions. Therefore you must use the dbx functions instead. John Coder On Sat, 2002-11-02 at 14:35, Micah Stevens wrote: It doesn't appear you have the PHP MySQL functions installed. When you run phpinfo() you should get something like: mysql MySQL Supportenabled Active Persistent Links1 Active Links1 Client API version3.23.39 MYSQL_MODULE_TYPEbuiltin MYSQL_SOCKET/var/lib/mysql/mysql.sock MYSQL_INCLUDE MYSQL_LIBS The command I've always used for this during compile time is --with-mysql without any options. I'm not sure what =shared, /tmp does, but apparently it's not doing the trick. -Micah At 03:32 PM 11/2/2002 +0100, Wouter wrote: Hello, I've a rather complete php install on redhat 7.3, yet I cant't get php to connect to mysql. I get: Fatal error: Call to undefined function: mysql_connect() in ... It seems that the necessary packages are installed: [rootaxon ~]# rpm -qa | grep php php-4.1.2-7.3.4 php-mysql-4.1.2-7.3.4 asp2php-0.76.2-1 php-devel-4.1.2-7.3.4 php-ldap-4.1.2-7.3.4 php-imap-4.1.2-7.3.4 [rootaxon ~]# rpm -qa | gi mysql mysql-3.23.49-3 mysql-server-3.23.49-3 php-mysql-4.1.2-7.3.4 mysql-devel-3.23.49-3 mysqlclient9-3.23.22-6 I've attached the start of phpinfo() at the end... Any ideas? Maybe php.ini needs some change, but I can't figure which one.. Thanks, Wouter PHP Version 4.1.2 System Linux stripples.devel.redhat.com 2.4.18-11smp #1 SMP Thu Aug 15 06:41:59 EDT 2002 i686 unknown Build Date Aug 21 2002 Configure Command './configure' 'i386-redhat-linux' '--prefix=/usr' '--exec-prefix=/usr' '--bindir=/usr/bin' '--sbindir=/usr/sbin' '--sysconfdir=/etc' '--datadir=/usr/share' '--includedir=/usr/include' '--libdir=/usr/lib' '--libexecdir=/usr/libexec' '--localstatedir=/var' '--sharedstatedir=/usr/com' '--mandir=/usr/share/man' '--infodir=/usr/share/info' '--prefix=/usr' '--with-config-file-path=/etc' '--enable-force-cgi-redirect' '--disable-debug' '--enable-pic' '--disable-rpath' '--enable-inline-optimization' '--with-bz2' '--with-db3' '--with-curl' '--with-dom=/usr' '--with-exec-dir=/usr/bin' '--with-freetype-dir=/usr' '--with-png-dir=/usr' '--with-gd' '--enable-gd-native-ttf' '--with-ttf' '--with-gdbm' '--with-gettext' '--with-ncurses' '--with-gmp' '--with-iconv' '--with-jpeg-dir=/usr' '--with-mm' '--with-openssl' '--with-png' '--with-pspell' '--with-regex=system' '--with-xml' '--with-expat-dir=/usr' '--with-zlib' '--with-layout=GNU' '--enable-bcmath' '--enable-debugger' '--enable-exif' '--enable-ftp' '--enable-magic-quotes' '--enable-safe-mode' '--enable-sockets' '--enable-sysvsem' '--enable-sysvshm' '--enable-discard-path' '--enable-track-vars' '--enable-trans-sid' '--enable-yp' '--enable-wddx' '--without-oci8' '--with-imap=shared' '--with-imap-ssl' '--with-kerberos=/usr/kerberos' '--with-ldap=shared' '--with-mysql=shared,/usr' '--with-pgsql=shared' '--with-snmp=shared,/usr' '--with-snmp=shared' '--enable-ucd-snmp-hack' '--with-unixODBC=shared' '--enable-memory-limit' '--enable-bcmath' '--enable-shmop' '--enable-versioning' '--enable-calendar' '--enable-dbx' '--enable-dio' '--enable-mbstring' '--enable-mbstr-enc-trans' '--with-apxs=/usr/sbin/apxs' snip dbx dbx support enabled dbx version 1.0.0 supported databases MySQLbr /ODBCbr /PostgreSQLbr /Microsoft SQL Serverbr /FrontBase -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DB] mysql_connect problem rh7.3
It doesn't appear you have the PHP MySQL functions installed. When you run phpinfo() you should get something like: mysql MySQL Supportenabled Active Persistent Links1 Active Links1 Client API version3.23.39 MYSQL_MODULE_TYPEbuiltin MYSQL_SOCKET/var/lib/mysql/mysql.sock MYSQL_INCLUDE MYSQL_LIBS The command I've always used for this during compile time is --with-mysql without any options. I'm not sure what =shared, /tmp does, but apparently it's not doing the trick. -Micah At 03:32 PM 11/2/2002 +0100, Wouter wrote: Hello, I've a rather complete php install on redhat 7.3, yet I cant't get php to connect to mysql. I get: Fatal error: Call to undefined function: mysql_connect() in ... It seems that the necessary packages are installed: [root@axon ~]# rpm -qa | grep php php-4.1.2-7.3.4 php-mysql-4.1.2-7.3.4 asp2php-0.76.2-1 php-devel-4.1.2-7.3.4 php-ldap-4.1.2-7.3.4 php-imap-4.1.2-7.3.4 [root@axon ~]# rpm -qa | gi mysql mysql-3.23.49-3 mysql-server-3.23.49-3 php-mysql-4.1.2-7.3.4 mysql-devel-3.23.49-3 mysqlclient9-3.23.22-6 I've attached the start of phpinfo() at the end... Any ideas? Maybe php.ini needs some change, but I can't figure which one.. Thanks, Wouter PHP Version 4.1.2 System Linux stripples.devel.redhat.com 2.4.18-11smp #1 SMP Thu Aug 15 06:41:59 EDT 2002 i686 unknown Build Date Aug 21 2002 Configure Command './configure' 'i386-redhat-linux' '--prefix=/usr' '--exec-prefix=/usr' '--bindir=/usr/bin' '--sbindir=/usr/sbin' '--sysconfdir=/etc' '--datadir=/usr/share' '--includedir=/usr/include' '--libdir=/usr/lib' '--libexecdir=/usr/libexec' '--localstatedir=/var' '--sharedstatedir=/usr/com' '--mandir=/usr/share/man' '--infodir=/usr/share/info' '--prefix=/usr' '--with-config-file-path=/etc' '--enable-force-cgi-redirect' '--disable-debug' '--enable-pic' '--disable-rpath' '--enable-inline-optimization' '--with-bz2' '--with-db3' '--with-curl' '--with-dom=/usr' '--with-exec-dir=/usr/bin' '--with-freetype-dir=/usr' '--with-png-dir=/usr' '--with-gd' '--enable-gd-native-ttf' '--with-ttf' '--with-gdbm' '--with-gettext' '--with-ncurses' '--with-gmp' '--with-iconv' '--with-jpeg-dir=/usr' '--with-mm' '--with-openssl' '--with-png' '--with-pspell' '--with-regex=system' '--with-xml' '--with-expat-dir=/usr' '--with-zlib' '--with-layout=GNU' '--enable-bcmath' '--enable-debugger' '--enable-exif' '--enable-ftp' '--enable-magic-quotes' '--enable-safe-mode' '--enable-sockets' '--enable-sysvsem' '--enable-sysvshm' '--enable-discard-path' '--enable-track-vars' '--enable-trans-sid' '--enable-yp' '--enable-wddx' '--without-oci8' '--with-imap=shared' '--with-imap-ssl' '--with-kerberos=/usr/kerberos' '--with-ldap=shared' '--with-mysql=shared,/usr' '--with-pgsql=shared' '--with-snmp=shared,/usr' '--with-snmp=shared' '--enable-ucd-snmp-hack' '--with-unixODBC=shared' '--enable-memory-limit' '--enable-bcmath' '--enable-shmop' '--enable-versioning' '--enable-calendar' '--enable-dbx' '--enable-dio' '--enable-mbstring' '--enable-mbstr-enc-trans' '--with-apxs=/usr/sbin/apxs' Server API Apache Virtual Directory Support disabled Configuration File (php.ini) Path /etc/php.ini ZEND_DEBUG disabled Thread Safety disabled Zend logo This program makes use of the Zend Scripting Language Engine: Zend Engine v1.1.1, Copyright (c) 1998-2001 Zend Technologies PHP 4.0 Credits Configuration PHP Core Directive Local Value Master Value allow_call_time_pass_reference On On allow_url_fopen 1 1 always_populate_raw_post_data 0 0 arg_separator.input arg_separator.output asp_tags Off Off auto_append_file no value no value auto_prepend_file no value no value browscap no value no value default_charset no value no value default_mimetype text/html text/html define_syslog_variables Off Off disable_functions no value no value display_errors On On display_startup_errors Off Off doc_root no value no value enable_dl On On error_append_string no value no value error_log no value no value error_prepend_string no value no value error_reporting 2039 2039 expose_php On On extension_dir /usr/lib/php4 /usr/lib/php4 file_uploads no value no value gpc_order GPC GPC highlight.bg #FF #FF highlight.comment #FF9900 #FF9900 highlight.default #CC #CC highlight.html #00 #00 highlight.keyword #006600 #006600 highlight.string #CC #CC html_errors On On ignore_user_abort Off Off implicit_flush Off Off include_path .:/usr/share/pear .:/usr/share/pear log_errors Off Off magic_quotes_gpc On On magic_quotes_runtime Off Off magic_quotes_sybase Off Off max_execution_time 30 30 memory_limit 8M 8M open_basedir no value no value output_buffering no value no value output_handler no value no value post_max_size 8M 8M precision 14 14 register_argc_argv On On register_globals On On safe_mode Off Off safe_mode_exec_dir no value no value safe_mode_gid Off Off safe_mode_include_dir no value no value sendmail_from [EMAIL PROTECTED] [EMAIL PROTECTED] sendmail_path /usr/sbin/sendmail -t -i
Re: [PHP-DB] mysql_connect problem rh7.3
While Micah is correct, you do have mysql support on php but as a dbs not the built in php fuctions. Therefore you must use the dbx functions instead. John Coder On Sat, 2002-11-02 at 14:35, Micah Stevens wrote: It doesn't appear you have the PHP MySQL functions installed. When you run phpinfo() you should get something like: mysql MySQL Supportenabled Active Persistent Links1 Active Links1 Client API version3.23.39 MYSQL_MODULE_TYPEbuiltin MYSQL_SOCKET/var/lib/mysql/mysql.sock MYSQL_INCLUDE MYSQL_LIBS The command I've always used for this during compile time is --with-mysql without any options. I'm not sure what =shared, /tmp does, but apparently it's not doing the trick. -Micah At 03:32 PM 11/2/2002 +0100, Wouter wrote: Hello, I've a rather complete php install on redhat 7.3, yet I cant't get php to connect to mysql. I get: Fatal error: Call to undefined function: mysql_connect() in ... It seems that the necessary packages are installed: [rootaxon ~]# rpm -qa | grep php php-4.1.2-7.3.4 php-mysql-4.1.2-7.3.4 asp2php-0.76.2-1 php-devel-4.1.2-7.3.4 php-ldap-4.1.2-7.3.4 php-imap-4.1.2-7.3.4 [rootaxon ~]# rpm -qa | gi mysql mysql-3.23.49-3 mysql-server-3.23.49-3 php-mysql-4.1.2-7.3.4 mysql-devel-3.23.49-3 mysqlclient9-3.23.22-6 I've attached the start of phpinfo() at the end... Any ideas? Maybe php.ini needs some change, but I can't figure which one.. Thanks, Wouter PHP Version 4.1.2 System Linux stripples.devel.redhat.com 2.4.18-11smp #1 SMP Thu Aug 15 06:41:59 EDT 2002 i686 unknown Build Date Aug 21 2002 Configure Command './configure' 'i386-redhat-linux' '--prefix=/usr' '--exec-prefix=/usr' '--bindir=/usr/bin' '--sbindir=/usr/sbin' '--sysconfdir=/etc' '--datadir=/usr/share' '--includedir=/usr/include' '--libdir=/usr/lib' '--libexecdir=/usr/libexec' '--localstatedir=/var' '--sharedstatedir=/usr/com' '--mandir=/usr/share/man' '--infodir=/usr/share/info' '--prefix=/usr' '--with-config-file-path=/etc' '--enable-force-cgi-redirect' '--disable-debug' '--enable-pic' '--disable-rpath' '--enable-inline-optimization' '--with-bz2' '--with-db3' '--with-curl' '--with-dom=/usr' '--with-exec-dir=/usr/bin' '--with-freetype-dir=/usr' '--with-png-dir=/usr' '--with-gd' '--enable-gd-native-ttf' '--with-ttf' '--with-gdbm' '--with-gettext' '--with-ncurses' '--with-gmp' '--with-iconv' '--with-jpeg-dir=/usr' '--with-mm' '--with-openssl' '--with-png' '--with-pspell' '--with-regex=system' '--with-xml' '--with-expat-dir=/usr' '--with-zlib' '--with-layout=GNU' '--enable-bcmath' '--enable-debugger' '--enable-exif' '--enable-ftp' '--enable-magic-quotes' '--enable-safe-mode' '--enable-sockets' '--enable-sysvsem' '--enable-sysvshm' '--enable-discard-path' '--enable-track-vars' '--enable-trans-sid' '--enable-yp' '--enable-wddx' '--without-oci8' '--with-imap=shared' '--with-imap-ssl' '--with-kerberos=/usr/kerberos' '--with-ldap=shared' '--with-mysql=shared,/usr' '--with-pgsql=shared' '--with-snmp=shared,/usr' '--with-snmp=shared' '--enable-ucd-snmp-hack' '--with-unixODBC=shared' '--enable-memory-limit' '--enable-bcmath' '--enable-shmop' '--enable-versioning' '--enable-calendar' '--enable-dbx' '--enable-dio' '--enable-mbstring' '--enable-mbstr-enc-trans' '--with-apxs=/usr/sbin/apxs' snip dbx dbx support enabled dbx version 1.0.0 supported databases MySQLbr /ODBCbr /PostgreSQLbr /Microsoft SQL Serverbr /FrontBase -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php