web 2.0

How to use PHP & Oracle (oci8) Config OCI8 for php

How to use PHP & Oracle (oci8) Config OCI8 for php This is the guideline/example scripts how to use PHP and Oracle Database , Config php support oci function.

ShotDev Focus:
- PHP & config oci function

Solution

Fatal error: Call to undefined function oci_connect() in C:\AppServ\www\myphp\php_oracle.php on line 7

..

PHP Warning: PHP Startup: Unable to load dynamic library ‘C:/AppServ\php5\ext\php_oci8.dll’ - The specified
procedure could not be found.\r\n in Unknown on line 0

..

Warning: oci_connect() [function.oci-connect]: OCIEnvNlsCreate() failed. There is something wrong with
your system - please check that PATH includes the directory with
Oracle Instance Client libraries in C:\AppServ\www\myphp\php_oracle.php on line 7

..

Warning: oci_connect() [function.oci-connect]: ORA-12705: Cannot access NLS data files or invalid environment
specified in C:\AppServ\www\myphp\php_oracle.php on line 7

Solve Problem

Step 1
Oracle Instance Client Download file oraociei10.dll,orannzsbb10.dll,oci.dll

http://www.oracle.com/technology/software/tech/oci/instantclient/htdocs/winsoft.html Version 10.2.0.4

Step 2
Copy file oraociei10.dll,orannzsbb10.dll,oci.dll
to C:\Windows\System32

PHP & Oracle (oci8) Config OCI8 Support For PHP

Step 3
Change Registry NLS_LANG

Start -> Run -> Regedit -> HKEY_LOCAL_MACHINE -> SOFTWARE -> ORACLE -> NLS_LANG

PHP & Oracle (oci8) Config OCI8 Support For PHP

*** Delete or input Null value

Step 4
Copy php_oci8.dll to extension folder. ….. download file php_oci8.dll
and open oci function php.ini

Start -> Run -> php.ini

PHP & Oracle (oci8) Config OCI8 Support For PHP

check extestion folder

PHP & Oracle (oci8) Config OCI8 Support For PHP

copy file to C:/Appserv\php5\ext

PHP & Oracle (oci8) Config OCI8 Support For PHP

remove (;) at line php_oci8.dll

Restart Web Server

Test oci function


<?
phpinfo();
?>

Screenshot

PHP & Oracle (oci8) Config OCI8 Support For PHP

1 Star2 Stars3 Stars4 Stars5 Stars6 Stars7 Stars8 Stars9 Stars10 Stars (2 votes, average: 5.50 out of 10)
Loading ... Loading ...

One Response to “How to use PHP & Oracle (oci8) Config OCI8 for php”

  1. 1description…

Leave a Reply

You must be logged in to post a comment.