MySQL Forums
Forum List  »  PHP

Re: Problem link PHP 5.1.2 + Mysql 5.0.20 + IIS 6.0
Posted by: William
Date: April 14, 2006 09:11AM

Jason Gray wrote:
> I have the same problem only I'm running
>
> PHP 5.1.2
> Mysql 5.0.20
> IIS 6.0
>
> extension_dir = "c:/php/ext/"
>
> extension=php_mysql.dll <-- Enabled / already
> uncoment -- not exists when check <?php
> phpinfo(); ?>
> extension=php_mysqli.dll <-- Enabled / already
> uncoment -- not exists when check <?php
> phpinfo(); ?>
>
> And I get a error in phpMyAdmin that say:
>
> phpMyAdmin - Error
> Cannot load mysql extension. Please check your PHP
> configuration. - Documentation
>
> or if i tell phpMyAdmin to use mysqli in the cofig
> file then I get:
>
> phpMyAdmin - Error
> Cannot load mysqli extension. Please check your
> PHP configuration. - Documentation
>
> I think there is a bug in PHP 5.1.2 probing for
> extensions. It should not matter even if you have
> don't have any MySQL database running the
> extension should still show up in phpinfo(). I
> have install php many times (25-30) before.
>
> Any one find a fix?


I found a fix and I have posted it already but I'll repeat it here :)
It turns out that PHP 5.0 removed support for new versions of mysql and you have to manually set it up:

1) Make sure your libmysql and php_mysql/php_mysqli .dlls are there and the php_ ones are enabled.
Note) If you are on linux, sorry this doesn't cover you as I have no idea how to do it for a linux, I'm on windows.
2) Go to windows control panel, if its in advanced mode, turn it into classic view for ease of use for the next step:
3) Find 'System' and open it, click on the advanced tab.
4) Click on [Environment Variables].
5) Under System Variables, click new.
6) In the dialog that pops up, there should be two text boxes.
In the name bpx, type:
PHPRC
7) In the value of this variable is where you installed it, for example, I installed it into C:\PHP, and that was exactly what I typed:
C:\PHP

8) Were almost finished!
9) Restart your computer and it should work.

The original solution that was published by me can be found at:
http://forums.mysql.com/read.php?52,81903,82429#msg-82429

No, I will NOT fix your computer!
Oh, alright then!

I HATE it when things go wrong :@ :@

Options: ReplyQuote


Subject
Written By
Posted
Re: Problem link PHP 5.1.2 + Mysql 5.0.20 + IIS 6.0
April 14, 2006 09:11AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.