Error with model Generator

Hi all!

My environment:

Windows XP Pro; XAMPP 1.7; PHP Version 5.2.8 for my physical folder and verified installation requisite (except for a warning for PDO SQLite extension, PDO PostgreSQL extension, Memcache extension, APC extension, but they should not be very important now because I work with MySql).

  • To avoid connection errors I had to specify port=3307 in the connection string in main.php, for user root.

  • Yii demos seems to work fine.

Logging in my page http://localhost/yii/index.php?r=gii I tried to execute Model Generator, specifying one table of my database stated in the connection, but I always receive an error message from Win XP due to a problem with Apache and the file php_pdo_mysql.dll

PHPinfo indicates that PDO_MySQL is correctly loaded: "PDO Driver for MySQL, client library version 5.1.30"

What’s wrong?

What (and where) can I check?

Thanks!

Antonio

the error?

NOTE: The mysql default port is 3306

I got the standard pop-up Windows message that ask the user to communicate (or not) the error to Microsoft.

Next time I can capture that message and post it.

About MySql port: yes, I know that default port is 3306 but I use a MySql installation external to XAMPP.

While XAMPP MySql uses the usual 3306, my installation uses 3307.

I verified the need to specify 3307 port: if I do not specify it, Yii goes into error because cannot find the database.

So it’s not a Yii or PHP error…

I would suggest you to try some different LAMP instalation… EasyPHP for example… just to check if it will work…

I had the same problem. I just loaded the rewrite module in my apache config then it works. I hope this will help!

Hi all!

The problem is related to php_pdo_mysql.dll loading and is solved by copying libmysql.dll to Apache’s dll path (e.g. apache/bin).

I found this suggestion in PHP: MySql PDO Manual

Bye.