W3C home > Mailing lists > Public > whatwg@whatwg.org > December 2004

[whatwg] Wish: Restrict Image Size on Upload

From: Matthew Thomas <mpt@myrealbox.com>
Date: Tue, 28 Dec 2004 14:46:08 +1300
Message-ID: <3EA087F5-5872-11D9-8D70-000A95AD3972@myrealbox.com>
On 27 Dec, 2004, at 11:08 PM, Ian Hickson wrote:
>
> On Mon, 27 Dec 2004 what at keepthebyte.ch wrote:
>>
>> It would be useful to be able to define a bounding box of allowed
>> picture width and height when uploading picture(s). The UA would need 
>> to check if the selected picture(s) is/are inside the allowed range 
>> (min - max width & height). With picture I generally mean the 
>> internet
>> widespread formats (png, gif, jpg).
>
> With the coming of high-resolution monitors, the pixel size of the 
> image will presumably become less important, as monitors will be 
> getting more pixels per centimeter.
> ...

As others have said, this is not a very compelling reason to reject the 
request. What bothers me more is why it should be a UA's job to 
restrict uploads based on pixel size of images, and not on other 
things.

Should UAs be able to restrict uploads based on the bit depth of 
images? (For some purposes only 1-bit images are desired.) How about 
based on whether images are animated or not? (Some forums may want 
avatars to be non-animated only.) How about based on the number of 
pages in a PDF or RTF document? (Job application forms may want resum?s 
to be no more than /n/ pages.) How about based on the sample rate of 
audio files? Or on the framerate of video files? At what point do you 
say "okay, that's the server's job, not the client's", and why?

(Keep in mind that any restriction done by the client will still have 
to be done by the server as well, to guard against buggy or malicious 
UAs.)

-- 
Matthew Thomas
http://mpt.net.nz/
Received on Monday, 27 December 2004 17:46:08 UTC

This archive was generated by hypermail 2.3.1 : Monday, 13 April 2015 23:08:20 UTC