How to Connect Oracle Database in PHP

In this post we have explained about how to connect oracle database in PHP using XAMPP server. You need to use oci driver for oracle connection with PHP. There are two different ways to connect PHP and Oracle.

how-to-connct-oracle-database-connection-in-php-using-xampp-server

PHP and Oracle Connection in First Method:

Enable Oracle Database 12c Instant Client in php.ini file to remove semicolon

PHP and Oracle Connection in Second Method:

Install php_oci12 extension depends on oracle version.

Once you have complete the above process and please execute the following a sample connection program to check the oracle connectivity with PHP.

Create a file connect.php

Fetch records from table

Thanks for reading this article. If you have any queries and please comment in the below.

Comments

comments

phpexpertise

I’m Blogger and Programming Blog, Tutorials, PHP, MySQL, jQuery, Laravel, Wordpress and Codeigniter