We did this recently (input type=file):

We had problems getting the file received via a Delphi ISAPI app, and ended
up writing a C++ cgi to receive the files.

Be aware the client can click stop on their browser so you need a timeout on
the server to abort the process.

Steve.

> -----Original Message-----
> From: Dennis Chuah [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, 27 June 2000 09:45
> To: Multiple recipients of list offtopic
> Subject: RE: [DUG-OFFTOPIC]: An HTML forms question
> 
> 
> 
> > -----Original Message-----
> > Posted on behalf of a friend...
> >
> > > I'm trying to find a way of uploading files (from client to
> > server) without
> > > having an applet at the client side. Am using forms on
> > client-side (with
> > > "input type=file") to go get the filename, and I think I
> > found a reference
> > > to sending it with the "post" action on submit (will have
> > to check that),
> > > but haven't yet found the code to decode/extract it at the
> > server end.
> >
> > Does anyone know if transferring a file to server is possible
> > in this manner...
> > I'd hate to see the guy running down the wrong road for too
> > long on this one...
> 
> I'd suggest:
> 
> <form method="post" enctype="multipart/form-data">
> 
> as this will cause the browser to send the form elements as 
> multipart MIME
> packets in the HTTP request.  The file (if one is specified) 
> is sent as one
> of those MIME packets.
> 
> 
> On the server end, it really depends on the server you use.  
> With CGI, the
> whole request is passed to the CGI program via stdin.  On 
> UNIX machines,
> this is fine; but on Windows, stdin/out only handles text.  
> With ISAPI, it
> is the same idea, but is done in-memory - and it handles binary files.
> 
> 
> > > I'm trying to find a way of uploading files (from client to
> > server) without
> > > having an applet at the client side.
> 
> The applet still needs to go through the web server to upload the file
> (unless you use FTP).
> 
> 
> Regards,
> Dennis.
> 
> 
> --------------------------------------------------------------
> -------------
>   New Zealand Delphi Users group - Offtopic List - 
> [EMAIL PROTECTED]
>                   Website: http://www.delphi.org.nz
> 
---------------------------------------------------------------------------
  New Zealand Delphi Users group - Offtopic List - [EMAIL PROTECTED]
                  Website: http://www.delphi.org.nz

Reply via email to