[5807] in www-talk@info.cern.ch

home help back first fref pref prev next nref lref last post

Re: File upload in HTML forms

daemon@ATHENA.MIT.EDU (wmperry@spry.com)
Mon Sep 26 22:52:48 1994

Date: Tue, 27 Sep 1994 03:51:00 +0100
Errors-To: listmaster@www0.cern.ch
Errors-To: listmaster@www0.cern.ch
Reply-To: wmperry@spry.com
From: wmperry@spry.com
To: Multiple recipients of list <www-talk@www0.cern.ch>

Christian L. Mogensen writes:
> wmperry@spry.com writes:
> 
> >   The basic format is:
> > POST /cgi-bin/foobar HTTP/1.0
> > [more http headers]
> > Content-type: multipart/x-www-form-data; 
> > 	      separator=-some-separator-for-www-form-data
> > ---some-separator-for-www-form-data
> > Content-id: NAME of form <input> tag
> 
> > the raw form data for the specific <input> tag
> 
> > ---some-separator-for-www-form-data
> > Content-id: next NAME
> > raw form data
> 
> 
> Wouldn't this benefit from the Content-length instead of separators?
> Especially since the browser knows the lengths of all items before
> submission.  i.e:
> 
> Content-type: multipart/x-www-form-data
> 
> Content-id: Name
> Content-length: 8
> Raw Data
> Content-id: AnotherName
> Content-length: 15
> More Raw Data
> 
> Content-id: etc etc...
> (ie: the last CRLF is not included in the data)

  I think you need both in a multipart message, don't you?  Forgot to put
in the content-length in my example code - will change that this afternoon.

-Bill P.

home help back first fref pref prev next nref lref last post