Jump to content


Photo

PHP and Oracle client


  • Please log in to reply
2 replies to this topic

#1 shashidhar

shashidhar
  • New Members
  • Pip
  • Newbie
  • 3 posts

Posted 21 November 2005 - 06:23 AM

Hi,
I have installed oracle client on my linux machine. When i try to run the following commad

$c = OCILogon('user', 'password', 'database');

it display the following error.

Fatal error: Call to undefined function: ocilogon() in /var/www/html/db.php on line 2

I am not able to make out what is worng. Please help.

Regards,
Shashidhar

#2 shashidhar

shashidhar
  • New Members
  • Pip
  • Newbie
  • 3 posts

Posted 22 November 2005 - 06:51 AM

I found the solution to my problem. In ./configure i had --disable-rpath, i just had to removed it.
And reinstalled the php with --with-oci8-client and --enable-sigchild. Now my php is able to run oci commands.

But a new problem!!!!! :-(

how do i configure tnsnames.ora to my php? I have tried the steps given in [a href=\"http://www.oracle.com/technology/pub/notes/technote_php_instant.html\" target=\"_blank\"]http://www.oracle.com/technology/pub/notes...hp_instant.html[/a]

but i get the following error.

Warning: ocilogon(): _oci_open_server: Error while trying to retrieve text for error ORA-12154 in /var/www/html/db.php on line 2

anyone knows what should be done now?

Regards,
Shashidhar

#3 jerry_th

jerry_th
  • New Members
  • Pip
  • Newbie
  • 3 posts

Posted 27 December 2005 - 02:01 PM

Try with installing Oracle instant client and set the env variable TNS_ADMIN
to where you have your tnsnames file. You can then check your access with
sqlplus to the user/db where you have your web server.




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users