path_info - orig_path_info (PHP5?)

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

    path_info - orig_path_info (PHP5?)

    This may be more of an Apache question, but after an upgrade at my
    remote host (one of them being from Php4 to Php5), $_SERVER['PATH_INFO']
    no longer contains any data. Instead, the string I am looking for is in
    $_SERVER['ORIG_PATH_INFO '] (never heard of that one before - I found it
    using phpinfo).

    Example URL:


    Before the upgrade $_SERVER['PATH_INFO'] would contain /Keyword. Now it
    is blank, and there is a new server variable, $_SERVER['ORIG_PATH_INFO ']
    that does contain /Keyword.

    Is this a Php5 issue, ... an Apache issue, ... something else?

    --
    *************** **************
    Chuck Anderson • Boulder, CO

    Everyone's journey should be different,
    so that we all are enriched
    in new and endless ways
    *************** **************
  • Csaba Gabor

    #2
    Re: path_info - orig_path_info (PHP5?)

    Chuck Anderson wrote:
    This may be more of an Apache question, but after an upgrade at my
    remote host (one of them being from Php4 to Php5), $_SERVER['PATH_INFO']
    no longer contains any data. Instead, the string I am looking for is in
    $_SERVER['ORIG_PATH_INFO '] (never heard of that one before - I found it
    using phpinfo).
    >
    Example URL:

    >
    Before the upgrade $_SERVER['PATH_INFO'] would contain /Keyword. Now it
    is blank, and there is a new server variable, $_SERVER['ORIG_PATH_INFO ']
    that does contain /Keyword.
    >
    Is this a Php5 issue, ... an Apache issue, ... something else?
    I don't think it's PHP, sounds like something else...
    I just checked my php 5.2 / Apache 2 and it is returning the PATH_INFO
    per your expectations (and no ORIG_PATH_INFO in sight).

    Csaba Gabor from Vienna

    Comment

    • Alvaro G. Vicario

      #3
      Re: path_info - orig_path_info (PHP5?)

      *** Chuck Anderson escribió/wrote (Sat, 01 Jul 2006 16:29:53 -0600):
      This may be more of an Apache question, but after an upgrade at my
      remote host (one of them being from Php4 to Php5), $_SERVER['PATH_INFO']
      no longer contains any data. Instead, the string I am looking for is in
      $_SERVER['ORIG_PATH_INFO '] (never heard of that one before - I found it
      using phpinfo).
      Check this Apache directive:

      AcceptPathInfo Directive
      Description: Resources accept trailing pathname information
      Syntax: AcceptPathInfo On|Off|Default
      Default: AcceptPathInfo Default
      Context: server config, virtual host, directory, .htaccess
      Override: FileInfo
      Status: Core
      Module: core
      Compatibility: Available in Apache 2.0.30 and later



      --
      -+ http://alvaro.es - Álvaro G. Vicario - Burgos, Spain
      ++ Mi sitio sobre programación web: http://bits.demogracia.com
      +- Mi web de humor con rayos UVA: http://www.demogracia.com
      --

      Comment

      • Chuck Anderson

        #4
        Re: path_info - orig_path_info (PHP5?)

        Csaba Gabor wrote:
        Chuck Anderson wrote:
        >
        >This may be more of an Apache question, but after an upgrade at my
        >remote host (one of them being from Php4 to Php5), $_SERVER['PATH_INFO']
        >no longer contains any data. Instead, the string I am looking for is in
        >$_SERVER['ORIG_PATH_INFO '] (never heard of that one before - I found it
        >using phpinfo).
        >>
        >Example URL:
        >http://example.com/index.php/Keyword
        >>
        >Before the upgrade $_SERVER['PATH_INFO'] would contain /Keyword. Now it
        >is blank, and there is a new server variable, $_SERVER['ORIG_PATH_INFO ']
        >that does contain /Keyword.
        >>
        >Is this a Php5 issue, ... an Apache issue, ... something else?
        >>
        >
        I don't think it's PHP, sounds like something else...
        I just checked my php 5.2 / Apache 2 and it is returning the PATH_INFO
        per your expectations (and no ORIG_PATH_INFO in sight).
        >
        Csaba Gabor from Vienna
        >
        >
        I finally found something about this.

        There seems to be a bug in Php when run as cgi that is not being addressed.


        After reading that, I think the easiest thing for me to do now is make
        my scripts check to see if PATH_INFO *or* ORIG_PATH_INFO is set.

        --
        *************** **************
        Chuck Anderson • Boulder, CO

        Everyone's journey should be different,
        so that we all are enriched
        in new and endless ways
        *************** **************

        Comment

        • Chuck Anderson

          #5
          Re: path_info - orig_path_info (PHP5?)

          Alvaro G. Vicario wrote:
          *** Chuck Anderson escribió/wrote (Sat, 01 Jul 2006 16:29:53 -0600):
          >
          >This may be more of an Apache question, but after an upgrade at my
          >remote host (one of them being from Php4 to Php5), $_SERVER['PATH_INFO']
          >no longer contains any data. Instead, the string I am looking for is in
          >$_SERVER['ORIG_PATH_INFO '] (never heard of that one before - I found it
          >using phpinfo).
          >>
          >
          Check this Apache directive:
          >
          AcceptPathInfo Directive
          Description: Resources accept trailing pathname information
          Syntax: AcceptPathInfo On|Off|Default
          Default: AcceptPathInfo Default
          Context: server config, virtual host, directory, .htaccess
          Override: FileInfo
          Status: Core
          Module: core
          Compatibility: Available in Apache 2.0.30 and later
          I was being a little daft here. Php is run as cgi on the server.

          --
          *************** **************
          Chuck Anderson • Boulder, CO

          Everyone's journey should be different,
          so that we all are enriched
          in new and endless ways
          *************** **************

          Comment

          Working...