execute php from cmd (undefined function OCILogon)

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • ragonz
    New Member
    • Jul 2008
    • 24

    execute php from cmd (undefined function OCILogon)

    i tried to execute php file from cmd line. i'm using xampp version 1.67 with windows server 2003 as the OS. it'll also include oracle as the database,which means OCILogon() will be called in my php file and so other functions. i already configured the php.ini so that it connects to oracle. in web page, i can access the database(oracle ). But the problem is, when i tried to execute the php file through cmd line with this code :

    c:\xampp\php\ph p4\php.exe c:\test.php

    it shows error, which says "call to undefined function OCILogon() bla.bla..bla... ."

    any suggestions??? really need help here

    thx in advance
  • zorgi
    Recognized Expert Contributor
    • Mar 2008
    • 431

    #2

    Comment

    • Atli
      Recognized Expert Expert
      • Nov 2006
      • 5062

      #3
      Hi.

      Even tho you have configured the php.ini file to enable the extension, the php.ini file that the CGI version of PHP uses isn't necessarily the same one the Apache module uses.

      Try to execute this via the command line:
      [code=php]<?php
      phpinfo(INFO_GE NERAL);
      ?>[/code]
      Look for the Loaded Configuration File line. See if it is the right file.

      Comment

      • ragonz
        New Member
        • Jul 2008
        • 24

        #4
        Hehhee, thx mod. It works

        Comment

        Working...