OCI Connect Issue at Windows Server 2012 with PHP

2019-01-29 13:04发布

OCI Connect

Based upon the above, it states that one should avoid OCI connection on Windows. Have someone configured it on Windows? I have gone through all other threads, this and this, using Windows Server 2012 with PHP 5.6 and Oracle 11g but still having issue:

Call to undefined function oci_connect()

I have set the path: c:/instantclient_12_1

Under php.ini, one can see:

;extension=php_oci8.dll
extension=php_oci8_11g.dll

while under /php/ext

there is only file: php_oci8_12c.dll

This is the output of phpinfo() to show configure command:

cscript /nologo configure.js "--enable-snapshot-build" "--disable-isapi" "--enable-debug-pack" "--without-mssql" "--without-pdo-mssql" "--without- pi3web" "--with-pdo-oci=c:\php-sdk\oracle\x86\instantclient_12_1\sdk,shared" "--with-oci8-12c=c:\php-sdk\oracle\x86\instantclient_12_1\sdk,shared" "--enable-object-out-dir=../obj/" "--enable-com-dotnet=shared" "--with-mcrypt=static" "--without-analyzer" "--with-pgo"

What is the reason of an error undefined function oci_connect()?

标签: php oci php-5.6
1条回答
啃猪蹄的小仙女
2楼-- · 2019-01-29 13:29

Try using following:

extension=php_oci8_12c.dll

in your php.ini, in my case (Windows Server 2008, PHP 5.6) that helped.

查看更多
登录 后发表回答