[squeak-dev] Re: Can't access www.squeaksource.com from Squeak
Andreas Raab
andreas.raab at gmx.de
Thu Mar 25 22:17:11 UTC 2010
On 3/25/2010 2:43 PM, Hans-Martin Mosner wrote:
> HTTP 1.1 defines that Location must be an absolute URI, so
> squeaksource.com is clearly violating the specs, but browser seem to
> handle the Location header just fine.
Welcome to the real world. *Nobody* respects that rule :-)
Here is what we do:
"Grab the url and retry. Note that although the HTTP spec says that the
location header contains 'a single absolute URI' we've found that some
places use a relative URI instead (and are therefore in violation of
the spec).
Since asUrlRelativeTo: deals with absolute URLs too, that's not a problem."
url := (header copyAfter: $:) withBlanksTrimmed asUrlRelativeTo: url.
Cheers,
- Andreas
More information about the Squeak-dev
mailing list
|