This week I had a little trouble to install the WampServer Windows 7. The problem of installation and compatibility with Windows 7 was resolved by reinstalling a newer version of WampServer – WampServer 2.0i (July 11 2009). But, still, gave error when trying to connect using Firebird, something like “Fatal error: Call to undefined function ibase_connect()” and other.
Actually I tried so many things that I do not know for sure which one made it work :P. So, follow step 1 and 2, it operates, go to 3, and so on. What matters here is that now is working and so I decided to post if anyone's with similar problem.
The detail is that I've tested both the WAMP and XAMPP, and both worked well, considering the environment with Windows 7 + Firebird 2.5 + WampServer2.0i (PHP 5.3.0).
I put the DLL php_interbase.dll, fbclient.dll and gds32.dll that utilizei, Available for download (see above), in case you need. So, lets get down to, here's a tip:
(1) Copy php_interbase.dll para C:\wampbinphpphp5.3.0ext. (Do this if the dll does not exist)
(2) Enable (remove the comma from the beginning of the line) option extension = php_interbase.dll no C:\wampbinapacheApache2.2.11binphp.ini. NOTE: If you do not have this entry, add it!
Now, test one: Restart Apache and see if the connection is already working. Is negative, go ahead:
(3) Copy and fbclient.dll gds32.dll to C:\wampbinapacheApache2.2.11bin. It would be good that these files were also in C:\WindowsSystem32, If you have not already.
(4) Install new version Firebird-184.108.40.206074 _ 1_Win32
(5) Unleash the windows firewall 7 the door 3050 (Firebird) (Advanced Settings> Inbound Rules> New Rule> Door> … )
Remember to restart the Apache service every time you test the operation.
Below is a simple example of connecting PHP Firebird x:
conexao.php | Connecting PHP to Firebird
1 2 3 4 5 6
<?PHP $hostname = 'localhost:/Wamp/www/database/MEUBANCODEDADOS.gdb '; $username = 'sysdba'; $password = 'masterkey'; ibase_connect($hostname, $username, $password); ?>