Technote Details :: Issue with a PHAKT 2 database connection: Unidentified error:
Issue
I get a message saying "Unidentified error:" when using PHAKT2 and Dreamweaver MX.
Reason
This is an uncaught error when querying the database, and it's generated by Macromedia Dreamweaver MX.
It usually happens when something wrong happened during the communication between Dreamweaver, the testing server and the database server.
Solution
In order to better understand and possibly resolve this issue, follow the checklist below:
The PHP version on the testing server is higher than 4.1.1
You have installed the 6.1 updater (Macromedia Dreamweaver MX 6.0 users).
PHP supports the extension for your specific database, and this is active in the php.ini or linked statically. (e.g. php_pgsql for PostgreSQL). You can check this by loading a <?php phpinfo(); ?> page and searching for your database name.
Dreamweaver has the rights to write files on the testing server. (try creating a folder outside Dreamweaver in your ftp client, into the root site folder on the testing server, using the same connection type and user/pass as the ones you specified to Dreamweaver).
The ADOdb and the includes folders exist on your testing server root site folder. If they are not there please upload them from the local folder (Upload the folders to the testing server from Dreamweaver by pressing Ctrl+Shift+U).
MAC users should verify if on the testing server they have a file called _mmServerScripts in the site root. (This file should actually be a folder. Please erase it and manually create the folder on both the testing server and the local server.).
If you are using RedHat 8 with the default MySQL database you should add the testing server name into the /etc/hosts on the database server. (Due to a MySQL 3.x problem on RedHat 8 only, the server dies and break the connection in the middle of the negotiations even if the username@hosts have the rights to connect).
Non-MAC users should try to remove the _mmServerScripts folder on both local and testing server and then should try to retest the connection.
If you have checked all above issues you may try implementing the next solution which is a little more technical:
Go into the _mmServerScripts folder from your testing server where you should find 2 files : MMHTTPDB.php and ADODB.php . Edit the second line from the MMHTTPDB.php which it should look like this:
$ debug_to_file = false;
and change it to:
$ debug_to_file = true;
Open Macromedia Dreamweaver MX again and create a new testing page in your site. Open the Connection dialog and setup the new connection. After completing all the fields from the connection dialog click the test button.
A new file will be generated inside the _mmServerScripts folder on your testing server named "log.txt". Open it and you should see inside the communication that was made during the test call by the testing server and the database server. Also you should see if any errors appeared during this call and if the communication failed unexpectedly.