Re: php File upload

From: Date: Fri, 08 Aug 2008 19:41:36 +0000
Subject: Re: php File upload
References: 1 2 3 4 5 6 7 8 9 10 11  Groups: php.general 
Request: Send a blank email to php-general+get-277920@lists.php.net to get a copy of this message
mike wrote: > On 8/8/08, Andrew Ballard <aballard@gmail.com> wrote: > >> I've not had to upload such large files over HTTP, so forgive my >> ignorance, but on the request end isn't the only difference between >> PUT and POST the verb used in the request (and the intent of the >> operation)? What can you do with PUT that cannot also be handled the >> same in POST? I don't see any implementations doing it, but from what >> I can tell the spec allows you to use Content-Range in the request >> headers that your client sends to PUT/POST the same way the server >> sends them in the response headers when serving a GET request. > > POST sends mime-encoded > PUT is raw (AFAIK) That's not necessarily a big difference between the two - mime-encoded can also be plain 8-bit. > Using PUT you can do pure file uploads, have smart clients that tell > the server where to resume, it's not mime encoded (so not extra > bytes), it can be processed as a web request via PHP, it can be done > over SSL for security ... Same as POST then :-) (except for the resume bit). I still don't see much of a difference. It doesn't matter much to me, I'd just like to understand what the real difference is. Maybe I need to go and read RFC2616. /Per Jessen, Zürich

« previous php.general (#277920) next »