W3C home > Mailing lists > Public > www-style@w3.org > June 2005

Re: Is Safari right or wrong? Should "display: none" prevent form elements from being submitted?

From: Matthew Raymond <mattraymond@earthlink.net>
Date: Thu, 23 Jun 2005 05:40:39 -0400
Message-ID: <42BA8397.70905@earthlink.net>
To: Allan Sandfeld Jensen <kde@carewolf.com>
CC: www-style@w3.org

Allan Sandfeld Jensen wrote:
> On Thursday 23 June 2005 08:11, Brian Sexton wrote:
>>Should dynamically setting "display: none" for a form input element prevent
>>that element from being submitted--that is, treated as though it does not
>>exist at all--or should it merely be removed from the rendering of a
> I don't know about forms, but normally display: none elements should be 
> treated as they do not exists at all.

    No, because then the stylesheet would be controlling behavior in 
addition to presentation. Should changing the stylesheet or switching to 
no style (as in Firefox) affect whether or not form controls are 
successful? I don't see a use case for that, and even if there was one, 
XBL could cover it.

    In any event, the name of the property is "display", so if it can 
affect form control submission, it's poorly labeled.

> To only remove them from rendering you should use display: hidden.

    Near as I can determine, this value is proprietary or never existed 
in the first place. It does not exist in the CSS1, CSS2, CSS 2.1 or CSS3 
Box Model specifications. From searching the web, it would appear that 
the "hidden" value originates from a typo in a WCAG 2.0 working draft:


    In this case, the text should have probably said "visibility: 
hidden" instead of "display: hidden". Since a "hidden" value for display 
would likely lead to suggested values like "hidden-inline" or 
"hidden-table-cell", it hardly seems logical anyways.
Received on Thursday, 23 June 2005 09:40:48 UTC

This archive was generated by hypermail 2.3.1 : Monday, 2 May 2016 14:27:18 UTC