View Single Post
  #6 (permalink)  
Old 11-15-04, 22:47
savbill savbill is offline
Registered User
 
Join Date: Feb 2004
Posts: 533
Quote:
Originally Posted by bloom
Hello Ive recently installed Apache 2, PHP 5.02 and MYSQL 4.1 on Windows XP.

I am now tyring to connect to a database called bloomdb i have created in comman prompt mySQL.

The error i get is: Call to undefined function mysql_connect() on line 4 of temp_con.

Now i have searched the net for this problem and found it is that mysql is not enabled?. Not with PHP 5 by default, I think i have done what you said in this guide correctly but not too sure.

When you say uncomment what does that mean?, can any of you nice people explain how to enable it in very SIMPLE SIMPLE terms please.
1. check the setup process again follow the steps and notes I've written.
Part of the process tells you to copy files from the PHP setup folder, where you installed PHP to the 'Program Files/Apache Group/Apache2/' folder.

One of these files is the PHP.ini file. Open the PHP.ini file in a plain text editor (like 'Note Pad') search or find the line "extension=php_mysql.dll" If there's a ';' semi-colon in front of this line it means it's commented and has no effect of the php settings. Remove the ';' from the line and it is 'uncommneted'. Changes in the PHP.ini have no effect until the Apache server is 'bounced' or restarted. Use the Apache tray icon 'Restart' command for this.

to check your settings copy this code into a file save it as 'test.php' in your htdocs folder ./apache/htdocs/test.php Then open the file in the browser 'http://loacalhost/test.php' to check your PHP settings.

PHP Code:
<?php
 
echo 'PHP is working.<br>';
 echo 
phpinfo();
?>
.
__________________
~

Bill
Reply With Quote