Join 500+ Software Testing professionals. Solve problem and get your problem solved. Register Now!

1
PHP MySQL extension (mysql) is not loaded

Solved 2 Answers 142 Views Others
1 2
I am getting below while installing web application on WAMP
 
PHP MySQL extension (mysql) is not loaded.
Check your settings in php.ini.
 
Under certain Linux / BSD distributions, the PHP MySQL extension is a separate package.
 
Debian: Run "apt-get install php5-mysql" and restart your webserver.
 
FreeBSD: Install the php5-mysql port, or configure MySQL support in the php-extensions port and restart your webserver.

2 Answers

0
Best answer
0

I uninstalled WAMP and used 

WAMPSERVER (64 BITS & PHP 5.5) 2.5

it worked for me.

answered by (151 points)
selected by
0
0

At first make sure you have mysql installed properly. You can ensure it just by checking that whether you can access mysql using mysql command promp. So if you mysql is working then probably it is not loading. For that follow the steps given below

First of all, you must find your php.ini. It could be anywhere but if you create a small php file with the

<?php phpinfo(); ?>

script it will tell you where it is. Just look at the path of loaded configuration file. Common places include /etc/apache/, /etc/php4/apache2/php.ini, /etc/php5/apache2/php.ini or even /usr/local/lib/php.ini for Windows it may be C:\Users\username\PHP\php.ini

Edit your server’s php.ini and look for the following line. Remove the ‘;’ from the start of the line and restart Apache. Things should work fine now!

;extension=mysql.so

should become

extension=mysql.so

For windows it will be

;extension=mysql.dll

should become

extension=mysql.dll
 

 

answered by (151 points)

Your answer

Your name to display (optional):
Privacy: Your email address will only be used for sending these notifications.
Anti-spam verification:
To avoid this verification in future, please log in or register.
...