Can . (period) be part of the path part of an URL?

I don’t see where RFC1738 disallows periods (.) in URLs. Here are some excerpts from there:

hpath          = hsegment *[ "https://stackoverflow.com/" hsegment ]
hsegment       = *[ uchar | ";" | ":" | "@" | "&" | "=" ]
uchar          = unreserved | escape
unreserved     = alpha | digit | safe | extra
safe           = "$" | "-" | "_" | "." | "+"

So the answer to your question is: Yes, http://www.example.com/module.php/lib/lib.php is a valid URL.

Leave a Comment