I apologize if this is a very basic question.
I just started learing PHP and MySQL, I am reading "PHP and MySQL" by Larry 
Ullman, I also have access to PHP 5 by Julie Meloni. I reached Chapter 6 of 
Ullman's book and got stuck.
I have the following code:
//This file contains the database access information. This file also 
establishes a connection
//to MYSQL and selects the database.
//Set the database access information as constants
define ('DB_USER', 'masud');
define ('DB_PASSWORD', 'masud');
define ('DB_HOST', 'localhost');
define ('DB_NAME', 'masud');
//Make the connection and then select the database
$dbc = mysql_connect (DB_HOST, DB_USER, DB_PASSWORD);
I have a normal MySQL user as "masud", whose password is also "masud" and a 
database also called "masud". All this for learning purpose.
I get the following error message:
Fatal error: Call to undefined function mysql_connect() in C:\Program 
Files\Apache Group\Apache2\htdocs\CTA\mysql_connect.php on line 13

The books says:
If you receive an error that claims mysql_connect() is an undefined function, 
it means that PHP has not been compiled with MySQL support.
I have been running a test script with <? phpinfo(); ?> and I get the results 
I am running Windows XP with Apache 2 server and PHP5 5.0.3
I would appreciate if you could help me in any way, including pointing me to 
resources that can help get going.
Thank you,

Do you Yahoo!?
 Read only the mail you want - Yahoo! Mail SpamGuard.

Reply via email to