19 March 2007

Label tags are so hard to use... i charge $200US/hr

I really don’t understand why websites don’t use the label tag … it’s super simple and helps out accessibility so much … maybe it’s rocket science and i am a rocket scientist …

.
<label for="SOME_ID">Some nice description</label>
<input id="SOME_ID" type="text" value="" />

Now that is some complex code … most people do have labels but puts <strong> or <b> around them that could have been a <label>… but if you don’t want to display it … just put a display: none

first one is for free…

I was actually really surprised to see the big bad daddy google not using it … one input box and no label tag … shame … i love their simplistic approach and i love them so i’ll write the code for them for free …

.
<label for="q" style="display: none">Google Search</label>
<input id="q" name="q" value="" />

Some info…

HTML <label> tag
Forms > Labels
Accessibility and the Label Tag
Day 28: Labeling form elements
Better Accessible Forms – that’s right 2002 !!
Accessibilty Tip: LABEL Your Form Elements … good article but no form on the pages uses <label> tag … WTF ...

some benefits

get fancy with it …

digg does it really well … uses the label tag for “search the news…” and with a little css magic puts it inside the input box … BRILIANT
Digg excellent use of labels

css beauty ... does a different approach … uses css magic to make it an icon … also BRILLIANT
css beauty excellent use of labels

There are plenty examples out there of people not using it… you know who you are ... i will charge a modest $200 an hour to put the complex <label> tags in …


 

comment

what they saidwho said it

Don’t forget the accesskey attribute on labels – makes it easier to jump to a field without using a mouse.

2007-03-19
Jeremy Weiskotten


note: you can only submit after you hit preview


nuff-respec is a weblog written by daniel bulli a senior web programmer in boston, ma.
more >

contact | resume | profile

recently :::

diversions :::

Using Flash And Staying Standards Compliant
Anyone who has ever worked with Flash on the web has likely come across the fact that embedding flash into a web page is usually no walk in the park...
A Design is Finished when...
This is probably the hardest part of designing for me.... 23 Pro designers weigh in with their opinions ...
JungleCrazy.com
Find all the Amazon.com products that are discounted by at least 70%
IETester
IETester is a free WebBrowser that allows you to have the rendering and javascript engines of IE8 beta 1, IE7 IE 6 and IE5.5 on Vista and XP, as well as the installed IE in the same process.
you still want more »