PHP and PEAR and MySQL Setup on Apache

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • john

    PHP and PEAR and MySQL Setup on Apache

    All:

    Very experienced developer, newbie to PHP. My situation:

    I have installed on my WIndows XP machine the following:
    * PHP 5.2.1
    * MySQL 5.0
    * Apache 2.2

    All of these are installed under C:\Program Files under their own
    directories.

    The PHP installation works fine. I can put PHP files under the Apache
    htdocs directory and have them run. My challenge now is getting the
    MDB2.php libraries to run - right now I am getting an MDB2.php not
    found error, which I believe is due to a include_path error...

    So, I have 2 PHP.INI files -- one in C:\Program Files\PHP and one in
    the htdocs directory of Apache. They both have the exact same
    include_path defined in the them. The very strange thing is that when
    I run phpinfo(), the include_path comes out to be .;C:\PHP5\PEAR.

    I have no idea where this value is coming from (it is the value for
    Master and Local). I have search everywhere -- the PHP.INI files, the
    registry, the ENV variables --- everywhere -- and I have no idea where
    this value is coming from. Where does phpinfo() pull the include_path
    from???

    If I can track down and change this value to the "real" PHP path, I
    may be able to get to the next hurdle of using MDB2!

    Any ideas?

    Many Thanks,
    John

  • Mike P2

    #2
    Re: PHP and PEAR and MySQL Setup on Apache

    PHP only uses one php.ini file at the time, and both of the ones you
    are editing may be wrong. Look for the PHPIniDir setting in your
    Apache conf\httpd.conf file. I think it should be near the end.

    Ex:
    PHPIniDir "C:/php"

    -Mike PII

    Comment

    • john

      #3
      Re: PHP and PEAR and MySQL Setup on Apache

      On Apr 27, 4:00 pm, Mike P2 <sumguyovrt...@ gmail.comwrote:
      PHP only uses one php.ini file at the time, and both of the ones you
      are editing may be wrong. Look for the PHPIniDir setting in your
      Apache conf\httpd.conf file. I think it should be near the end.
      >
      Ex:
      PHPIniDir "C:/php"
      >
      -Mike PII
      MIke:

      Thanks for the reply -- entire disk scan and no .;C:\PHP5\PEAR -
      anywhere, including the Windows registry! My conf\httpd.conf file is
      good, too - PHPIniDir is what I want -- C:\Program Files\PHP.

      Where PHP is getting its include_path is a complete mystery to me!

      Any additional thoughts appreciated -- thanks.

      John
      jpuopolo

      Comment

      • Jerry Stuckle

        #4
        Re: PHP and PEAR and MySQL Setup on Apache

        john wrote:
        All:
        >
        Very experienced developer, newbie to PHP. My situation:
        >
        I have installed on my WIndows XP machine the following:
        * PHP 5.2.1
        * MySQL 5.0
        * Apache 2.2
        >
        All of these are installed under C:\Program Files under their own
        directories.
        >
        The PHP installation works fine. I can put PHP files under the Apache
        htdocs directory and have them run. My challenge now is getting the
        MDB2.php libraries to run - right now I am getting an MDB2.php not
        found error, which I believe is due to a include_path error...
        >
        So, I have 2 PHP.INI files -- one in C:\Program Files\PHP and one in
        the htdocs directory of Apache. They both have the exact same
        include_path defined in the them. The very strange thing is that when
        I run phpinfo(), the include_path comes out to be .;C:\PHP5\PEAR.
        >
        I have no idea where this value is coming from (it is the value for
        Master and Local). I have search everywhere -- the PHP.INI files, the
        registry, the ENV variables --- everywhere -- and I have no idea where
        this value is coming from. Where does phpinfo() pull the include_path
        from???
        >
        If I can track down and change this value to the "real" PHP path, I
        may be able to get to the next hurdle of using MDB2!
        >
        Any ideas?
        >
        Many Thanks,
        John
        >
        And which php.ini file does phpinfo() say it's using?

        --
        =============== ===
        Remove the "x" from my email address
        Jerry Stuckle
        JDS Computer Training Corp.
        jstucklex@attgl obal.net
        =============== ===

        Comment

        • john

          #5
          Re: PHP and PEAR and MySQL Setup on Apache

          On Apr 29, 11:41 am, Jerry Stuckle <jstuck...@attg lobal.netwrote:
          john wrote:
          All:
          >
          Very experienced developer, newbie to PHP. My situation:
          >
          I have installed on my WIndows XP machine the following:
          * PHP 5.2.1
          * MySQL 5.0
          * Apache 2.2
          >
          All of these are installed under C:\Program Files under their own
          directories.
          >
          The PHP installation works fine. I can put PHP files under the Apache
          htdocs directory and have them run. My challenge now is getting the
          MDB2.php libraries to run - right now I am getting an MDB2.php not
          found error, which I believe is due to a include_path error...
          >
          So, I have 2 PHP.INI files -- one in C:\Program Files\PHP and one in
          the htdocs directory of Apache. They both have the exact same
          include_path defined in the them. The very strange thing is that when
          I run phpinfo(), the include_path comes out to be .;C:\PHP5\PEAR.
          >
          I have no idea where this value is coming from (it is the value for
          Master and Local). I have search everywhere -- the PHP.INI files, the
          registry, the ENV variables --- everywhere -- and I have no idea where
          this value is coming from. Where does phpinfo() pull the include_path
          from???
          >
          If I can track down and change this value to the "real" PHP path, I
          may be able to get to the next hurdle of using MDB2!
          >
          Any ideas?
          >
          Many Thanks,
          John
          >
          And which php.ini file does phpinfo() say it's using?
          >
          --
          =============== ===
          Remove the "x" from my email address
          Jerry Stuckle
          JDS Computer Training Corp.
          jstuck...@attgl obal.net
          =============== ===
          Jerry:

          I am starting Apache from a console (if that has anything to do w/
          it). phpinfo() tells me:
          Configuration File (php.ini) Path C:\WINDOWS

          There is no php.ini file in the C:\windows path whatsoever.

          Also, some other settings:

          extension_dir C:\php5 C:\php5 (directory does not exist)
          include_path .;C:\php5\pear (already described above)
          PHPRC C:\Program Files\PHP\
          PHP_PEAR_BIN_DI R C:\Program Files\PHP
          PHP_PEAR_DATA_D IR C:\Program Files\PHP\pear\ data
          PHP_PEAR_DOC_DI R C:\Program Files\PHP\pear\ docs
          PHP_PEAR_INSTAL L_DIR C:\Program Files\PHP\pear
          PHP_PEAR_PHP_BI N C:\Program Files\PHP\.\php .exe
          PHP_PEAR_SYSCON F_DIR C:\Program Files\PHP
          PHP_PEAR_TEST_D IR C:\Program Files\PHP\pear\ tests

          Any help appreciated... Thank you...

          John
          jpuopolo

          Comment

          • Jerry Stuckle

            #6
            Re: PHP and PEAR and MySQL Setup on Apache

            john wrote:
            On Apr 29, 11:41 am, Jerry Stuckle <jstuck...@attg lobal.netwrote:
            >john wrote:
            >>All:
            >>Very experienced developer, newbie to PHP. My situation:
            >>I have installed on my WIndows XP machine the following:
            >>* PHP 5.2.1
            >>* MySQL 5.0
            >>* Apache 2.2
            >>All of these are installed under C:\Program Files under their own
            >>directories .
            >>The PHP installation works fine. I can put PHP files under the Apache
            >>htdocs directory and have them run. My challenge now is getting the
            >>MDB2.php libraries to run - right now I am getting an MDB2.php not
            >>found error, which I believe is due to a include_path error...
            >>So, I have 2 PHP.INI files -- one in C:\Program Files\PHP and one in
            >>the htdocs directory of Apache. They both have the exact same
            >>include_pat h defined in the them. The very strange thing is that when
            >>I run phpinfo(), the include_path comes out to be .;C:\PHP5\PEAR.
            >>I have no idea where this value is coming from (it is the value for
            >>Master and Local). I have search everywhere -- the PHP.INI files, the
            >>registry, the ENV variables --- everywhere -- and I have no idea where
            >>this value is coming from. Where does phpinfo() pull the include_path
            >>from???
            >>If I can track down and change this value to the "real" PHP path, I
            >>may be able to get to the next hurdle of using MDB2!
            >>Any ideas?
            >>Many Thanks,
            >>John
            >And which php.ini file does phpinfo() say it's using?
            >>
            >--
            >============== ====
            >Remove the "x" from my email address
            >Jerry Stuckle
            >JDS Computer Training Corp.
            >jstuck...@attg lobal.net
            >============== ====
            >
            Jerry:
            >
            I am starting Apache from a console (if that has anything to do w/
            it). phpinfo() tells me:
            Configuration File (php.ini) Path C:\WINDOWS
            >
            There is no php.ini file in the C:\windows path whatsoever.
            >
            OK, so it's using the default settings.
            Also, some other settings:
            >
            extension_dir C:\php5 C:\php5 (directory does not exist)
            include_path .;C:\php5\pear (already described above)
            PHPRC C:\Program Files\PHP\
            PHP_PEAR_BIN_DI R C:\Program Files\PHP
            PHP_PEAR_DATA_D IR C:\Program Files\PHP\pear\ data
            PHP_PEAR_DOC_DI R C:\Program Files\PHP\pear\ docs
            PHP_PEAR_INSTAL L_DIR C:\Program Files\PHP\pear
            PHP_PEAR_PHP_BI N C:\Program Files\PHP\.\php .exe
            PHP_PEAR_SYSCON F_DIR C:\Program Files\PHP
            PHP_PEAR_TEST_D IR C:\Program Files\PHP\pear\ tests
            >
            Any help appreciated... Thank you...
            >
            John
            jpuopolo
            >
            Put a php.ini file with the settings you want in your c:\windows directory.

            Alternatively, you can do things like modify the registry to place the
            file anywhere you want. But for now just put it in c:\windows until you
            get things working.

            --
            =============== ===
            Remove the "x" from my email address
            Jerry Stuckle
            JDS Computer Training Corp.
            jstucklex@attgl obal.net
            =============== ===

            Comment

            Working...