Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

added REQUEST_URI to the PSGI spec

  • Loading branch information...
commit c6d7946ff486322e5d922c0c869413d9a16fc0ea 1 parent 0dd2975
Tatsuhiko Miyagawa miyagawa authored
Showing with 14 additions and 1 deletion.
  1. +3 −1 FAQ.pod
  2. +11 −0 PSGI.pod
4 FAQ.pod
View
@@ -481,7 +481,9 @@ with double encoding or decoding.
For web application frameworks that need more control over the actual
raw URI (such as L<Catalyst>), we made the C<REQUEST_URI> environment
hash key REQUIRED. The servers should set the undecoded (unparsed)
-original URI (containing the query string) to this key.
+original URI (containing the query string) to this key. Note that
+C<REQUEST_URI> is completely raw even if the encoded entities are
+URI-safe.
For comparison, WSGI (PEP-333) defines both C<SCRIPT_NAME> and
C<PATH_INFO> be decoded and Rack leaves it implementation dependent,
11 PSGI.pod
View
@@ -110,6 +110,17 @@ should be URI decoded by servers to be compatible to RFC 3875.
=item *
+C<REQUEST_URI>: The undecoded, raw request URL line. It is the raw URI
+path and query part that appears in the HTTP C<GET /... HTTP/1.x> line
+and doesn't contain URI scheme and host names.
+
+Unlike C<PATH_INFO>, this value SHOULD NOT be decoded by servers and
+hence it is an application's responsibility to properly decode paths
+to map URL to application handlers, when using C<REQUEST_URI> over
+C<PATH_INFO>.
+
+=item *
+
C<QUERY_STRING>: The portion of the request URL that follows the C<?>,
if any. May be empty, but is always required.
Please sign in to comment.
Something went wrong with that request. Please try again.