E-mail List Archives
Thread: Using `small` element for form error messages
Number of posts in this thread: 2 (In chronological order)
From: Chris Pearce
Date: Tue, Apr 02 2013 9:44PM
Subject: Using `small` element for form error messages
No previous message | Next message →
Hi,
Just a question on semantics and not sure if this would make things more
accessible? I was wondering about using the HTML5
`*small*<http://developers.whatwg.org/text-level-semantics.html#the-small-element>`
element for the likes of form error messages and/or form helper notes.
The link above says this:
*Small print typically features disclaimers, caveats, legal restrictions,
or copyrights. Small print is also sometimes used for attribution, or for
satisfying licensing requirements.*
With 'caveats' being the stand out.
What I mean by form helper notes is that some form inputs require
additional instructions on how to successfully complete the input that the
few words provided in the input label can't provide and I usually place
this text underneath the input or after it in terms of source order, I know
this text is best placed within the input `label` however sometimes it's
not possible due to layout considerations.
Right now the element of choice for these pieces of text (error/helper
notes) is a `p` with the relevant ARIA attr's appended.
Cheers,
Chris
From: Jukka K. Korpela
Date: Tue, Apr 02 2013 11:11PM
Subject: Re: Using `small` element for form error messages
← Previous message | No next message
2013-04-03 6:44, Chris Pearce wrote:
> Just a question on semantics and not sure if this would make things more
> accessible?
By "this" you seem to mean the use of the <small> element for error
messages. All that <small> really means is reduced font size. And this
tends to reduce rather than improve accessibility, though it may still
be acceptable for presentational reasons.
> The link above says this:
>
> *Small print typically features disclaimers, caveats, legal restrictions,
> or copyrights. Small print is also sometimes used for attribution, or for
> satisfying licensing requirements.*
It's all just talk. HTML5 drafts contain some contrived verbal
acrobatics aimed at saving <small>, <b>, <i>, and <u> as "allowed" tags,
pretending that they do not have their old presentational meaning. Just
ignore that. Nobody is going to change the real meaning (the real
effects) of such markup.
There are billions of web pages that use those tags as presentational,
and there is no way to infer programmatically what they "mean" beyond
that, i.e. what was the reason why the author decided to use them. So
browsers and assistive software and search engine will keep treating
them as presentational, or "physical" markup.
In authoring, it's really simple: use <small>, if you want something to
appear in reduced font size even when style sheets are absent or
disabled. Just remember that in many situations (such as speech
rendering, Braille rendering, and character cell browsers), there is no
such thing as reduced font size, i.e. anything you tried to convey with
<small> will be lost.
Yucca