Mysql support in apache /php

Hi Any experts on this out there? I have set up a mysql database running on a server. The database is loadable and can be interacted with via mysql client using a telnet session. A basic php script running on the httpd server <?php phpinfo() ?> returns a result suggesting mysql is supported ..under the dbx subheading of the return .. but if I run the "mysql_connect" command the web page shows a error saying that this function (mysql_connect()) is not supported .. I cannot work out why not. Secondly I would ideally have liked to create the database as non root .. but seem to only be allowed to do it as root. Other users can readily access it. The os is rh9. Oddly, setting this up locally on my laptop there is no problem in running mysql_connect despite the installation being essentially identical (although I did use mysql rpm binaries to set up mysql). Any thought appreciated Stephen :>)

Hi, Stephen Pearce wrote:
returns a result suggesting mysql is supported ..under the dbx subheading of the return .. but if I run the "mysql_connect" command the web page shows a error saying that this function (mysql_connect()) is not supported .. I cannot work out why not.
The dbx module is an abstraction layer from the normal database calls (ie, mysql_connect, mysql_query, pg_connect etc.). This means that dbx supports MySQL, not that PHP supports MySQL. If you tried to use dbx in this case with MySQL you'd probably get a similar error. I can't help you much more as I'm unfamiliar with how RH9 packages PHP and it's modules. I'd say you have to install some php-mysql.something.rpm and/or enable it in php.ini. Cheers Philip Murray Systems Engineer - Open2view.com webmaster(a)open2view.com
participants (2)
-
Philip Murray
-
Stephen Pearce