On Wed, Aug 06, 2003 at 05:41:17PM +0400, Oleg Broytmann wrote:
> I found that the problem is between Medusa and Quixote: QuixoteHandler
> incorrectly parses request.uri.
Could you be more specific?
> ***************
> *** 43,51 ****
> remote_addr, remote_port = request.channel.addr
> ! query_string = ''
> ! if '?' in request.uri:
> ! [request.uri, query_string] = request.uri.split('?', 1)
>
> --- 43,51 ----
> remote_addr, remote_port = request.channel.addr
> ! path, params, query_string, fragment = request.split_uri()
> ! if query_string and query_string[0] == '?':
> ! query_string = query_string[1:]
>
After looking at RFC 2396, I think that the existing code is more
correct. From RFC 2396:
This "generic URI" syntax consists of a sequence of four main
components:
://?
and later,
path = [ abs_path | opaque_part ]
path_segments = segment *( "/" segment )
segment = *pchar *( ";" param )
param = *pchar
pchar = unreserved | escaped |
":" | "@" | "&" | "=" | "+" | "$" | ","
So the params are part of the path. I _think_ the current behavior of
not treating them specially is okay. Regarding fragments:
When a URI reference is used to perform a retrieval action on the
identified resource, the optional fragment identifier, separated from
the URI by a crosshatch ("#") character, consists of additional
reference information to be interpreted by the user agent after the
retrieval action has been successfully completed. As such, it is not
part of a URI, but is often used in conjunction with a URI.
Therefore, fragments will not been seen by Quixote, they are handled by
user agents.
Neil