logo       

RE: connections to oracle...: msg#00501

Subject: RE: connections to oracle...
These functions are probably not loaded by default.  you can solve this by
preceding any calls with;

if(!extension_loaded('oracle')) {
        if(strtoupper(substr($PHP_OS,0,3)) == "WIN") dl('php_oracle.dll');
        else dl('php_oracle.so');
}

or something like this.

good luck,

Warren Vail
warren@xxxxxxxxxxxx


-----Original Message-----
From: Kit DeKat [mailto:kitdekat@xxxxxxxxxxxxx]
Sent: Tuesday, April 29, 2003 7:07 AM
To: php-windows@xxxxxxxxxxxxx
Subject: [PHP-WIN] connections to oracle...


ive  been trying to incorporate PHP into the webpages
throughout my company, but 90% of these pages are using
Perl make Oracle connections and handling all the SQL
calls. When i try to use the ora_* and oci* functions
in PHP, the errors messages tell me that said function
is undefined.

Fatal error: Call to undefined function: ocilogon()
     in D:\var\www\html\tgrounds\dbtest.php on line...

PHP code is as follows:

<?php
putenv('ORACLE_SID=kdk_db');
putenv('ORACLE_HOME=x:\oracle8i');
putenv('TNS_ADMIN=x:\oracle8i\network\admin');

$foo = exec("echo %ORACLE_SID%");
echo $foo;                               // prints 'kdk_db'

$conn = OCILogon("scott","tiger","") or  // <--- stops here
     die("Couldn't logon to database");

// $dbcon = ora_login("scott","tiger");

if( ora_open($dbcon) ){
     echo "opened successfully";
     ora_close($dbcon);
} else {
     echo "cant open dbconn: ". ora_error();
}
?>



Best regards,
  Kit DeKat                         mailto:kitdekat@xxxxxxxxxxxxx
  Systems Programmer

-----BEGIN PERL GEEK CODE BLOCK-----
Version: 0.01
P++>+++@$c---P6-R >++M+$O+>+++(++)$MA >+E+PU >+BD >++C >*$
D++S++>+++@X>++WP?MO?PP!n?CO?PO--o?G A--Ee+++Ev w+m!
------END PERL GEEK CODE BLOCK------


--
PHP Windows Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




-- 
PHP Windows Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

Recently Viewed:
science.linguis...    culture.sf.lite...    video.mplayer.c...    yellowdog.gener...    ietf.rfc822/199...    emacs.help/2002...    redhat.release....    kernel.speakup/...    java.openejb.de...    debian.devel.gt...    xfree86.newbie/...    bug-tracking.ma...    pam/2003-05/msg...    games.devel.ope...    user-groups.lin...    music.pancham/2...    network.mq.deve...    web.html.genera...    arklinux.bugs/2...    linux.ecasound/...    qnx.openqnx.dev...    org.user-groups...    file-systems.sf...    trustix.contrib...   
Home | blog view | USPTO Patent Archive | advertise | OSDir is an inevitable website. super tiny logo

Free Magazines

Cisco News
Receive a free quarterly e-newsletter with exclusive articles on how Cisco IT uses its own products and solutions to enable the business.
subscribe

Systems Management News, the newspaper for IT systems administration and data center managers! Each issue of Systems Management News is chock-full of news and analysis to help you understand what's happening in your field.
subscribe

The Enterprise Newsweekly eWeek is the essential technology information source for builders of e-business.
subscribe

Oracle Magazine Oracle Magazine contains technology strategy articles, sample code, tips, Oracle and partner news, how to articles for developers and DBAs, and more. Oracle (NASDAQ: ORCL) is the world's largest enterprise software company.
subscribe

Total Telecom Total Telecom is "The Economist of the communications industry".
subscribe