Detecting Internet Explorer w/ Web Connection

Skip to first unread message

Nevin Pratt

Mar 21, 2001, 8:27:00 PM3/21/01
OK, when using Web Connection, how exactly do you detect which browser
is in use by the client (Internet Explorer or NetScape)? Specifically,
I'd like to be able to detect whether or not Internet Explorer is in

The docs say:
The CGI Link Request part represents a request from a client
browser....You can retrieve the variables sent from the browser from the
cgiVars attribute. These variables provide information such as the
client and server software being used, the client host and user names,
and authentication information ...

So, I drop a CGI Link Request part on the canvas, and access it from
Smalltalk. From that part, I can send the #cgiVars message, and it
returns a dictionary of some values. However, it doesn't appear that
the browser info is available from there.

How exactly *do* you detect Internet Explorer?

I'm thinking of writing some JavaScript and have it execute on page
load-- but I really thought the CGI Link Request part could give me that

Nevin Pratt

Rich Snarski

Mar 22, 2001, 12:57:12 PM3/22/01
You will have to modify abtswtt.c and add in the variable your application
needs. I have added support for cookies, by adding HTTP_COOKIE. There's a
list of all the HTTP Headers out there in Web land! There are two places in
the file where you'll need to add the HTTP Header variable. Here's one:

while (current)
if ((strcmp(current->, "CONTENT_TYPE")==0) ||
(strcmp(current->, "PATH_INFO")==0) ||
(strcmp(current->, "QUERY_STRING")==0) ||
(strcmp(current->, "REQUEST_METHOD")==0) ||
(strcmp(current->, "XWSI_CONTENT_DATA")==0))
current = current->next;


"Nevin Pratt" <> wrote in message

Reply all
Reply to author
0 new messages