[Seaside] Scamper vs. non-Squeak browser
Jim Menard
jimm at io.com
Tue May 13 08:15:30 CEST 2003
Avi,
On Monday, May 12, 2003, at 11:00 PM, Avi Bryant wrote:
>
> On Mon, 12 May 2003, Jim Menard wrote:
>
>> When I try to use Seaside from within Scamper, it displays the error
>> message
>>
>> error occured retrieving http://localhost:9090/seaside/rate: Could
>> not
>> resolve the server named:
>
> I played around with this a bit, and the problem is definitely with
> Scamper - or rather, with the HTTPSocket class that it uses. This is a
> really fragile HTTP client, as I've found when trying to use it before
> -
> in this case, it's not properly supporting relative paths in redirects.
> That particular problem looks like it can be fixed by changing the
> '../'
> string literal in HTTPSocket class>>expandUrl:ip:port: to '/' instead
> (I'm
> completely perplexed by the use of '../' in this method), but after
> doing
> this I immediately ran into another problem, that seems like it might
> be
> related to Scamper mistreating the '@' sign in Seaside urls. It's
> possible that someone could also fix this one fairly easily, but in
> general I'm not optimistic about Scamper being useful for Seaside work
> until someone revamps the HTTP client implementation (which I
> understand
> Stephen is trying to lay some groundwork for anyway).
Thanks for the fix.
The problem with '@' (or '=' or ';') in the URL is that they are not
legal URL characters. I only see the latter two in my Seaside URLs.
They get correctly encoded using String>>encodeForHTTP into '%3D' and
'%3B' respectively. See Character>>isSafeForHTTP for the definition of
legal characters.
I'd like to suggest that Seaside change the way that it encodes its
URLs. There are a few different possible approaches: run them through
String>>encodeForHTTP, turn the 'k=3;xyzzy' part into parameters like
'?k=3&id=xyzzy', or use a different encoding scheme that sticks to
legal characters.
I will play around with these and let the group know what I come up
with.
Jim
--
Jim Menard, jimm at io.com, http://www.io.com/~jimm/
---- BEGIN META GEEK CODE ----
gc
---- END META GEEK CODE ----
More information about the Seaside
mailing list