Problems with the extensions using PHP 5.2 + IIS 6.0 + OCI8

Need help installing PHP, configuring a script, or configuring a server? Then come on in and post your questions! We'll try to help the best we can!

Moderator: General Moderators

Post Reply
sisuka
Forum Newbie
Posts: 6
Joined: Wed Dec 13, 2006 4:59 am

Problems with the extensions using PHP 5.2 + IIS 6.0 + OCI8

Post by sisuka »

Hello,

I've just installed PHP to run on IIS and it works (I can create variables, objects, etc). Now I want to use the OCI8 functions in order to connect to a DataBase, but I get this error message:

"Fatal error: Call to undefined function oci_connect() in C:\inetpub\wwwroot..."

This is happening also if I call a mysql function or whatever.

I have already uncommented the line "extension=php_oci8.dll" in php.ini and I have included the extensions directory in "extension_dir", but it still doesn't work.

I have rebooted the server many times as well, and I'm sure I've modified the right "php.ini" file.

Do yo have any idea of what I could do?

Thank you very much in advance

Natalia
User avatar
volka
DevNet Evangelist
Posts: 8391
Joined: Tue May 07, 2002 9:48 am
Location: Berlin, ger

Post by volka »

call

Code: Select all

<?php phpinfo(); ?>
it will tell you which php.ini has to be changed.
sisuka
Forum Newbie
Posts: 6
Joined: Wed Dec 13, 2006 4:59 am

I've already checked that

Post by sisuka »

Yes, and it says:

Configuration File (php.ini) Path: C:\WINDOWS\php.ini

And that's the right php.ini that I've changed.

thanks anyway

Natalia
sisuka
Forum Newbie
Posts: 6
Joined: Wed Dec 13, 2006 4:59 am

Extension_dir value

Post by sisuka »

Hi again,

I've seen that the following directives' values are as follows:

doc_root no value no value
docref_ext no value no value
docref_root no value no value

extension_dir .;c:\php\ext .;c:\php\ext

Do you think it has something to do with my problem?

I've also checked that "php_oci8.dll" is in c:\php\ext.

I've realized that in php.ini, it doesn't say anything about "OCI8" or any extension loaded...

Natalia
User avatar
volka
DevNet Evangelist
Posts: 8391
Joined: Tue May 07, 2002 9:48 am
Location: Berlin, ger

Re: Extension_dir value

Post by volka »

sisuka wrote:I've realized that in php.ini, it doesn't say anything about "OCI8" or any extension loaded...
?
sisuka wrote:I have already uncommented the line "extension=php_oci8.dll" in php.ini
Try changing another value, e.g. error_reporting, in your php.ini and check wether phpinfo() reflects the change.
sisuka
Forum Newbie
Posts: 6
Joined: Wed Dec 13, 2006 4:59 am

Extensions

Post by sisuka »

Yes, I've changed "display_errors" and I get different results, so it's loading the right "php.ini".

I've also printed the extensions array by get_extensions_loaded() and it is:

Array (
[0] => bcmath
[1] => calendar
[2] => com_dotnet
[3] => ctype
[4] => session
[5] => filter
[6] => ftp
[7] => hash
[8] => iconv
[9] => json
[10] => odbc
[11] => pcre
[12] => Reflection
[13] => date
[14] => libxml
[15] => standard
[16] => tokenizer
[17] => zlib
[18] => SimpleXML
[19] => dom
[20] => SPL
[21] => wddx
[22] => xml
[23] => xmlreader
[24] => xmlwriter
[25] => ISAPI )

By saying
"I've realized that in php.ini, it doesn't say anything about "OCI8" or any extension loaded... "

I meant that in the phpinfo() I can't see anything about OCI8 loaded, sorry.

Natalia
User avatar
volka
DevNet Evangelist
Posts: 8391
Joined: Tue May 07, 2002 9:48 am
Location: Berlin, ger

Post by volka »

And the requirements mentioned at http://de2.php.net/oci8 are met?
sisuka
Forum Newbie
Posts: 6
Joined: Wed Dec 13, 2006 4:59 am

Post by sisuka »

Yes, I've already seen that. Anyway I think the problem is in php, since the extensions are not loaded. I get the same result if I use mysqlconnect(), so it's not a OCI8 problem.

Thanks for your attention :)
User avatar
volka
DevNet Evangelist
Posts: 8391
Joined: Tue May 07, 2002 9:48 am
Location: Berlin, ger

Post by volka »

Try the php_bzip2 extension, it has no dependencies. If it doesn't show up in phpinof() either I'm clueless.
sisuka
Forum Newbie
Posts: 6
Joined: Wed Dec 13, 2006 4:59 am

Post by sisuka »

Ok,I'll try that. I'll say what happens.

Thank you very much for your help!
Post Reply