Cookies

Timothy O'Malley timo at alum.mit.edu
Wed Mar 21 00:46:05 EST 2001


[[ This message was both posted and mailed: see
   the "To," "Cc," and "Newsgroups" headers for details. ]]

hola.

> Thanks for your help and persistence.  I have come to an adequate
> compromise solution. . . .

Here's a wacky idea.

You could generate the id on the server or client side.  If the
client generates it in JavaScript, then he sends it to the server.  If
the server generates it, then he already has it.  In either case, the
the server who responds with an web page that includes an HTTP link
that points to the following URL
 
         http://localhost:8080/id=1234

On this page, you instruct the user to
    1) start up your Python application
    2) click on the link

The Python application should include a small (and stupid) HTTP sever
that listens on port 8080 of the localhost.  When it detects a
connection, it reads the ID out of the requested URL.  (In the above
example, the ID is the string "1234".)

When the user clicks on the link, the client browser makes a request
to the Python application running on his machine.  By this mechanism
is the unique key passed to the application.  (To be nice, the Python
application should respond with a nice web page.)



More information about the Python-list mailing list