Re: How to read POSTed data

2005-02-06 Thread Dan Perl
"Dan Perl" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Thanks, Pierre, this got me much further but I hit another stumbling > block. I can see now that CGIHTTPServer writes all the header lines into > os.environ and creates a subprocess for the script with os.popen2 or > os.p

Re: How to read POSTed data

2005-02-06 Thread Dan Perl
"Pierre Quentel" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > >> Pierre, I am repeating some questions I already stated in another thread, >> 'CGI POST problem', but do you have any opinions on how CGIHTTPServer's >> do_POST handles requests? It looks to me like it always expe

Re: How to read POSTed data

2005-02-06 Thread Pierre Quentel
Pierre, I am repeating some questions I already stated in another thread, 'CGI POST problem', but do you have any opinions on how CGIHTTPServer's do_POST handles requests? It looks to me like it always expects form data to be part of the POST command header, in the path of the URL, just like a

Re: How to read POSTed data

2005-02-06 Thread Dan Perl
"Pierre Quentel" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Here is an example of how to get the POST data : > > #def do_POST(self): > #ctype, pdict = > cgi.parse_header(self.headers.getheader('content-type')) > #length = int(self.headers.getheader('content

Re: How to read POSTed data

2005-02-06 Thread Pierre Quentel
Here is an example of how to get the POST data : #def do_POST(self): #ctype, pdict = cgi.parse_header(self.headers.getheader('content-type')) #length = int(self.headers.getheader('content-length')) #if ctype == 'multipart/form-data': #self.body = cgi.parse_m

Re: How to read POSTed data

2005-02-05 Thread Dan Perl
"HÃ¥kan Persson" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Hi. > > I am trying to set up a simple HTTP-server but I have problems reading > data that is beeing POSTed. > > class httpServer(BaseHTTPServer.BaseHTTPRequestHandler): >def do_POST(self): >input = self.rf