Running PHP 4 & PHP 5 together as modules

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

    Running PHP 4 & PHP 5 together as modules

    Folks,

    We would like to upgrade our servers to PHP 5 and PHP 4
    together as modules on the same server (not as cgi, not passing
    requests to another server). I did some extensive searching on
    this and we ran some tests over a year ago and did not find a
    solution (other than proxy forwarding to a PHP 5 configured server).

    When PHP went to version 4 from version 3, it was possible
    to run both at the same time, and have users select by file
    extension, i.e. .php4,.php5. It seems a naming conflict within
    the code itself prevents that from working with PHP 5. Has anyone
    discovered a way to do this?

    We are running apache 1.3.x on RHEL 4.

    Thanks!
    --
    John
    _______________ _______________ _______________ _______________ _______
    John Murtari Software Workshop Inc.
    jmurtari@follow ing domain 315.635-1968(x-211) "TheBook.Co m" (TM)
    Own TheBook.com today. Secure checkout and guided transfer support. No hidden fees.

  • Johnny

    #2
    Re: Running PHP 4 & PHP 5 together as modules


    "John Murtari" <jmurtari@thebo ok.comwrote in message
    news:x7r6r15s95 .fsf@hammer.the book.com...
    Folks,
    >
    We would like to upgrade our servers to PHP 5 and PHP 4
    together as modules on the same server (not as cgi, not passing
    requests to another server). I did some extensive searching on
    this and we ran some tests over a year ago and did not find a
    solution (other than proxy forwarding to a PHP 5 configured server).
    >
    When PHP went to version 4 from version 3, it was possible
    to run both at the same time, and have users select by file
    extension, i.e. .php4,.php5. It seems a naming conflict within
    the code itself prevents that from working with PHP 5. Has anyone
    discovered a way to do this?
    >
    We are running apache 1.3.x on RHEL 4.
    >
    Thanks!
    --
    John

    I've just done this successfully on apache2/gentoo. I have it running PHP4
    for for .php files and PHP5 for .php5 files.
    this doc won't all apply to your case but will likely give you enough
    pointers to get you up and running:


    hth, Johnny


    Comment

    • John Murtari

      #3
      Re: Running PHP 4 &amp; PHP 5 together as modules

      "Johnny" <reply@in.group .pleasewrites:
      > We would like to upgrade our servers to PHP 5 and PHP 4
      >together as modules on the same server (not as cgi, not passing
      >requests to another server). I did some extensive searching on
      >this and we ran some tests over a year ago and did not find a
      >solution (other than proxy forwarding to a PHP 5 configured server).
      >>
      > When PHP went to version 4 from version 3, it was possible
      >to run both at the same time, and have users select by file
      >extension, i.e. .php4,.php5. It seems a naming conflict within
      >the code itself prevents that from working with PHP 5. Has anyone
      >discovered a way to do this?
      >>
      > We are running apache 1.3.x on RHEL 4.
      >
      I've just done this successfully on apache2/gentoo. I have it running PHP4
      for for .php files and PHP5 for .php5 files.
      this doc won't all apply to your case but will likely give you enough
      pointers to get you up and running:

      >
      hth, Johnny
      Thanks for the message, I checked the link out. But it appears
      they are not BOTH running as modules on the same Apache server? The
      choices seemed to be to run one as CGI, or if you want both as modules
      use another instance of Apache. We were hoping someone may have knowledge
      of a solution that allows both to run as modules within the same
      Apache instance.

      --
      John
      _______________ _______________ _______________ _______________ _______
      John Murtari Software Workshop Inc.
      jmurtari@follow ing domain 315.635-1968(x-211) "TheBook.Co m" (TM)
      Own TheBook.com today. Secure checkout and guided transfer support. No hidden fees.

      Comment

      • Schraalhans Keukenmeester

        #4
        Re: Running PHP 4 &amp; PHP 5 together as modules

        John Murtari wrote:
        "Johnny" <reply@in.group .pleasewrites:
        >
        >> We would like to upgrade our servers to PHP 5 and PHP 4
        >>together as modules on the same server (not as cgi, not passing
        >>requests to another server). I did some extensive searching on
        >>this and we ran some tests over a year ago and did not find a
        >>solution (other than proxy forwarding to a PHP 5 configured server).
        >>>
        >> When PHP went to version 4 from version 3, it was possible
        >>to run both at the same time, and have users select by file
        >>extension, i.e. .php4,.php5. It seems a naming conflict within
        >>the code itself prevents that from working with PHP 5. Has anyone
        >>discovered a way to do this?
        >>>
        >> We are running apache 1.3.x on RHEL 4.
        >
        >I've just done this successfully on apache2/gentoo. I have it running PHP4
        >for for .php files and PHP5 for .php5 files.
        > this doc won't all apply to your case but will likely give you enough
        >pointers to get you up and running:
        >http://www.gentoo.org/proj/en/php/ph...figuration.xml
        >>
        >hth, Johnny
        >
        Thanks for the message, I checked the link out. But it appears
        they are not BOTH running as modules on the same Apache server? The
        choices seemed to be to run one as CGI, or if you want both as modules
        use another instance of Apache. We were hoping someone may have knowledge
        of a solution that allows both to run as modules within the same
        Apache instance.
        >
        Link is a bit dated, so your mileage may vary, but here goes:

        Comment

        • John Murtari

          #5
          Re: Running PHP 4 &amp; PHP 5 together as modules

          Schraalhans Keukenmeester <bitbucket@inva lid.spamwrites:
          >>> We would like to upgrade our servers to PHP 5 and PHP 4
          >>>together as modules on the same server (not as cgi, not passing
          >>>requests to another server). I did some extensive searching on
          >>>this and we ran some tests over a year ago and did not find a
          >>>solution (other than proxy forwarding to a PHP 5 configured server).
          >>>>
          >>> When PHP went to version 4 from version 3, it was possible
          >>>to run both at the same time, and have users select by file
          >>>extension, i.e. .php4,.php5. It seems a naming conflict within
          >>>the code itself prevents that from working with PHP 5. Has anyone
          >>>discovered a way to do this?
          >>>>
          >>> We are running apache 1.3.x on RHEL 4.
          Link is a bit dated, so your mileage may vary, but here goes:
          http://www.digitalsandwich.com/archi...he-server.html

          Yes, thanks for that. It has some of the best information
          I have found (I was suprised to see I had posted to the thread
          years ago). It does seem that it just isn't possible and keep
          'normal' functionality. I checked the php.net bug tracker and
          saw a request posted on this, the response was 'will not happen.'

          Not sure what the problem is, maybe a basic coding
          problem when 5 was created -- but I really do think it is
          slowing adoption of 5. We are a hosting provider, and it just
          makes it more difficult for us to transition and get our users
          to transition. Perhaps folks who are interested should submit
          some bug reeports at php.net?
          --
          John
          _______________ _______________ _______________ _______________ _______
          John Murtari Software Workshop Inc.
          jmurtari@follow ing domain 315.635-1968(x-211) "TheBook.Co m" (TM)
          Own TheBook.com today. Secure checkout and guided transfer support. No hidden fees.

          Comment

          • hansBKK

            #6
            Re: Running PHP 4 &amp; PHP 5 together as modules

            John Murtari <jmurtari@thebo ok.comwrote in
            news:x7veg9ekvr .fsf@hammer.the book.com:
            Yes, thanks for that. It has some of the best information
            I have found (I was suprised to see I had posted to the thread
            years ago). It does seem that it just isn't possible and keep
            'normal' functionality. I checked the php.net bug tracker and
            saw a request posted on this, the response was 'will not happen.'
            Not so bad running v4 as a module and v5 as CGI, as long as your customers
            can still set their v5 php.ini options as well as v4 .htaccess, no?

            Most people coding for 5 should be prepared to deal with a CGI environment
            by now, and the "legacy" people can stick with 4.

            Comment

            • John Murtari

              #7
              Re: Running PHP 4 &amp; PHP 5 together as modules

              hansBKK,
              > Yes, thanks for that. It has some of the best information
              >I have found (I was suprised to see I had posted to the thread
              >years ago). It does seem that it just isn't possible and keep
              >'normal' functionality. I checked the php.net bug tracker and
              >saw a request posted on this, the response was 'will not happen.'
              >
              Not so bad running v4 as a module and v5 as CGI, as long as your customers
              can still set their v5 php.ini options as well as v4 .htaccess, no?
              >
              Most people coding for 5 should be prepared to deal with a CGI environment
              by now, and the "legacy" people can stick with 4.
              Yes, thanks, but as you know running CGI is a lot more server
              overhead than as a built in module; also, on our apache server we
              use 'suexec' so that user's scripts run under their userid -- that makes
              some operations a lot easier (we provide web hosting). PHP runs as
              the 'server' so there are some different coding issues especially if
              an application wants to upload/create files on the server. If people
              got used to a CGI PHP environment, it might not be an easy transition
              if it was incorporated as a module.

              Because of a wide user base it just makes things simpler
              if the environment stays the same (as were able to do in the
              php 3 -php 4 transition).

              Best regards!

              --
              John
              _______________ _______________ _______________ _______________ _______
              John Murtari Software Workshop Inc.
              jmurtari@follow ing domain 315.635-1968(x-211) "TheBook.Co m" (TM)
              Own TheBook.com today. Secure checkout and guided transfer support. No hidden fees.

              Comment

              • Schraalhans Keukenmeester

                #8
                Re: Running PHP 4 &amp; PHP 5 together as modules

                John Murtari wrote:
                hansBKK,
                >
                >> Yes, thanks for that. It has some of the best information
                >>I have found (I was suprised to see I had posted to the thread
                >>years ago). It does seem that it just isn't possible and keep
                >>'normal' functionality. I checked the php.net bug tracker and
                >>saw a request posted on this, the response was 'will not happen.'
                >Not so bad running v4 as a module and v5 as CGI, as long as your customers
                >can still set their v5 php.ini options as well as v4 .htaccess, no?
                >>
                >Most people coding for 5 should be prepared to deal with a CGI environment
                >by now, and the "legacy" people can stick with 4.
                >
                Yes, thanks, but as you know running CGI is a lot more server
                overhead than as a built in module; also, on our apache server we
                use 'suexec' so that user's scripts run under their userid -- that makes
                some operations a lot easier (we provide web hosting). PHP runs as
                the 'server' so there are some different coding issues especially if
                an application wants to upload/create files on the server. If people
                got used to a CGI PHP environment, it might not be an easy transition
                if it was incorporated as a module.
                >
                Because of a wide user base it just makes things simpler
                if the environment stays the same (as were able to do in the
                php 3 -php 4 transition).
                >
                Best regards!
                >
                Do you mean eventually we will all have to switch to CGI instead of
                isapi module? Is there a reason for this trend I have missed perhaps?
                I thought the modular version was the preferred/recommended strategy.

                Sh.

                Comment

                Working...