What is the difference between $_SERVER['PATH_INFO'] and $_SERVER['ORIG_PATH_INFO']?

前端 未结 4 978
闹比i
闹比i 2020-12-16 21:32

What’s the difference between $_SERVER[\'PATH_INFO\'] and $_SERVER[\'ORIG_PATH_INFO\']? How do I use them?

When I run print_r($_SERVE

4条回答
  •  南方客
    南方客 (楼主)
    2020-12-16 22:16

    Prior to 5.2.4, PATH_INFO was apparently broken (not set) in the default configuration. Perhaps that's it.

    https://bugs.php.net/bug.php?id=31892

    The PHP manual says that ORIG_PATH_INFO is:

    Original version of 'PATH_INFO' before processed by PHP.

    Reference:
    http://php.net/manual/en/reserved.variables.server.php

提交回复
热议问题