Forum Moderators: coopster

Message Too Old, No Replies

help me more about php 5.0.2?

         

ngocdq

3:30 am on Nov 24, 2004 (gmt 0)

10+ Year Member



my problem is:
- I installed PHP 5.0.2 on my machine use WinXP with IIS & Mysql 4.1.7 embedded , reconfigured php.ini for change include_path =".;c:\inetpub\wwwroot".
I've tested the file test.php with simple code: phpinfo(), it worked ok.

But when i trying to connect to server by code :
<?
mysql_connect("localhost", "root", "mypassw");
?>
--> my IE alert me the error as follow:
"fatal error: undefined function mysql_connect() in c:\inetpub\wwwroot\test.php on line 2 ".
So i wonder why PHP_Server not understand the simple function mysql_connect()?
help me fix the error, thanks alot.

[edited by: ngocdq at 3:35 am (utc) on Nov. 24, 2004]

freeflight2

3:34 am on Nov 24, 2004 (gmt 0)

10+ Year Member



your php installation is missing the mysql extensions - if you compile it yourself you should add --with-mysql=[DIR] to ./configure ... read the manual or try to get a php5-mysql rpm installed

A_Dream

3:57 am on Nov 24, 2004 (gmt 0)

10+ Year Member



iis sucks, try apache....with iis you already have a problem..... I recommend Apache 1.3.x

coopster

12:08 pm on Nov 24, 2004 (gmt 0)

WebmasterWorld Administrator 10+ Year Member




Windows users will need to enable
php_mysql.dll
inside of
php.ini
and either copy
libmysql.dll
into the Windows system directory, or make it available to the
PATH
.

MySQL Functions [php.net]