Problem connecting MySQL Database in RADPHP XE2

Hi,

I was make a little application with RADPHP XE2 and i try to connect with a MySQL database...

I put in the form a Database non visual control from the palette and i fill the properties:
Connected=true
Databasename=MyDatabaseName
Dictionary=MyTableName
Host=localhost
UserName=user
UserPassword=psw

When I start I get the following error in my web browser:

Fatal error: Call to undefined function mysql_connect() in C:\PHP5\pear\rpcl\mysql.inc.php on line 257

Anyone know where can be the problem?

Thanks
josepmd_maddAsked:
Who is Participating?
 
josepmd_maddAuthor Commented:
Hi,

Finnally i was solved this question reinstalling RadPHP (HTML5 Builder) with a Administrator user...

Thanks
0
 
Randy DownsOWNERCommented:
Sounds like an issue with php.ini. You may have more than one .ini file.

Is this the path to php? C:\PHP5\pear\rpcl\mysql.inc.php
0
 
josepmd_maddAuthor Commented:
Hi,

Well... I am a two PHP folders:

C:\PHP5 ...

and

C:\Program Files (x86)\Embarcadero\RadPHP\4.0\php ...

I'm not sure what is the folder that PHP uses...
If i rename the first one (C:\PHP5) my project do not run...
The second one is the folder that RADPHP XE2 create in the installation...

In the folder of C:\PHP5 no exists any file named php.ini
In the folder of C:\Program Files (x86)\Embarcadero\RadPHP\4.0\php exists one file named php.ini

You know how can i know where is located the correct php.ini. Any environment variable...

Thanks
0
Cloud Class® Course: MCSA MCSE Windows Server 2012

This course teaches how to install and configure Windows Server 2012 R2.  It is the first step on your path to becoming a Microsoft Certified Solutions Expert (MCSE).

 
Randy DownsOWNERCommented:
Maybe this will help

http://docwiki.embarcadero.com/RadPHP/en/PHP_Settings

You can actually customize all PHP settings of RadPHP integrated web server:

    Open php.ini.template file, which is inside php folder in your RadPHP installation directory.
    Edit it. File is full of comments explaining everything, but you can also check php.ini directives chapter in PHP Documentation.
    Delete php.ini file in shared data folder. It will be replaced with the file you edited later.
0
 
Julian HansenCommented:
<?php
phpinfo();
?>

Try running the above script and checking that the mysql libraries are loaded - if in doubt do a search on mysql on the ouput and post that section here.
0
 
josepmd_maddAuthor Commented:
I was not found the solution in any response... I reinstall the product and it runs fine... I do not know the correct solution to solve this but the reinstallation was solve my problem...
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.