问题
I can not connect to a local bank in firebird.
Since I enabled the following extensions in php.ini but not getting any results.
extension=php_interbase.dll
extension="interbase.so"
extension=php_pdo_firebird.dll
I have also done interbase.so download the file and copy it to the folder:
/opt/lampp/lib/php/extensions/no-debug-non-zts-20131226/
I'm using:
- XAMPP 5.6.8 / PHP 5.6.8 (64bit)
- Linux 14.04 LTS (64bit)
My file database.php
$db['default'] = array(
'dsn' => '',
'hostname' => 'localhost',
'username' => 'SYSDBA',
'password' => 'masterkey',
'database' => 'localhost://home//ronald//fire//DEMO.GDB',
// 'port' => '3050',
'dbdriver' => 'ibase',
'dbprefix' => '',
'pconnect' => FALSE,
'db_debug' => TRUE,
'cache_on' => FALSE,
'cachedir' => '',
'char_set' => 'utf8',
'dbcollat' => 'utf8_general_ci',
'swap_pre' => '',
'encrypt' => FALSE,
'compress' => FALSE,
'stricton' => FALSE,
'failover' => array(),
'save_queries' => TRUE
);
Recalling that the problem is not in my connection string, as I've tried variations like:
- 'database' => 'localhost://home//ronald//fire//DEMO.GDB'
- 'database' => 'localhost:/home/ronald/fire/DEMO.GDB'
- 'database' => '/home/ronald/fire/DEMO.GDB'
- 'database' => '//home//ronald//fire//DEMO.GDB'
Error:
Thank you for your help!
EDIT
By suggesting "@Daniel Waghorn" ran a page with phpinfo()
The result can be seen in: http://codepen.io/anon/pen/LVdzRy?editors=100
I took to perform the following function get_loaded_extensions(false)
The function returns me the loaded modules. And as you can see the modules for the Firebird are not loaded.
- Core
- date
- ereg
- libxml
- openssl
- pcre
- sqlite3
- zlib
- bcmath
- bz2
- calendar
- ctype
- curl
- dba
- dom
- hash
- fileinfo
- filter
- ftp
- gd
- gettext
- SPL
- iconv
- session
- intl
- json
- ldap
- mbstring
- mcrypt
- standard
- mysqlnd
- mysqli
- mysql
- PDO
- pdo_mysql
- pdo_pgsql
- pdo_sqlite
- Phar
- posix
- Reflection
- imap
- shmop
- SimpleXML
- soap
- sockets
- exif
- sybase_ct
- sysvsem
- sysvshm
- tokenizer
- wddx
- xml
- xmlreader
- xmlrpc
- xmlwriter
- xsl
- zip
- apache2handler
- pgsql
- mhash
Now how can I load the Firebird modules to run with XAMPP START?
回答1:
Just copy fbclient.dll and gds32.dll to apache/bin/ folder and restart apache.
This work for me anfter hours of research.
回答2:
I suggest everyone to use Easyphp Devserver (www.easyphp.org) instead of wamp or xampp specially for connecting on Firebird Database (ibase_connect or pdo).
来源:https://stackoverflow.com/questions/31252469/call-to-undefined-function-ibase-connect-in-codeigniter