httpd-apreq-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Oskari 'Okko' Ojala" <>
Subject Re: [PATCH] to accept file uploads from Nokia Series 60 phones
Date Sun, 13 Apr 2003 17:11:36 GMT
On 13 Apr 2003, Joe Schaefer wrote:

> Thanks alot!  I'm +1 for having this functionality in libapreq-1.2, 
> but perhaps we should be using a case-insensitive test (like strcasecmp)
> instead of strEQ in this section of code.

Whichever is faster. :) Then again, next up there may be a browser 
sending "FILENAME" or "FileName", so case-insensitive comparing might be 

> We actually don't have any code for handling the "multiple files" case
> mentioned above.

Actually, I think the RFC means "in the case of multiple parts" there. The 
phone sends a couple of other fields too, but only one file upload per POST.

Anyway, without the patch I see no Apache::Upload object in Perl, with 
the patch I do. But the phone uploads them one-photo-by-POST-request, so 
I haven't experimented with multiple files in same request.

> > Content-Disposition: form-data; name="ImageData"; filename="Photo(21).jpg"
> > Content-Type: image/bmp
>                 ^^^^^^^^^                                               ^^^
> Interesting- the Content-Type appears to be incorrect here, no?
> Good luck on submitting a bugfix to M$ :-).

Oops. I just replaced my local file name from my message and got 
caught! :) IE does send the correct content type and the full path 
of the file in the "filename" parameter. :)

The main point was that IE uses "filename" and the Nokia phone "Filename". 

Before submitting the patch to the list I captured phone's and IE's POSTs 
with netcat, then used netcat to submit the POSTs to the server with both 
"filename" and "Filename". Before the patch, "filename" worked and 
"Filename" didn't. After both worked.

	Oskari "Okko" Ojala


View raw message