SitePoint Sponsor

User Tag List

Results 1 to 5 of 5

Thread: Title attribute on input tag

  1. #1
    SitePoint Wizard dominique's Avatar
    Join Date
    Dec 2000
    Location
    orbis terrarum
    Posts
    1,523
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Title attribute on input tag

    I have some <input type="checkbox" /> tags that do not have labels. Their use is clear to sighted people, and the others can probably figure it out easy enough but I was hoping to make it even simpler.

    Since I have no <label for=""> I was thinking of using the title="" attribute. Does anyone know if screen readers will read the title attribute on an input tag or should I really be looking to use the label tag?

  2. #2
    bronze trophy
    Join Date
    Dec 2004
    Location
    Sweden
    Posts
    2,666
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Simon Pieters

  3. #3
    Guru Meditation Error gnarly's Avatar
    Join Date
    Dec 2003
    Location
    Cheltenham, United Kingdom
    Posts
    692
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    No, screen-readers don't read the title attribute by default. The label element is where it's at.
    Olly Hodgson
    thinkdrastic.net

  4. #4
    SitePoint Wizard dominique's Avatar
    Join Date
    Dec 2000
    Location
    orbis terrarum
    Posts
    1,523
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Does it matter if the label text is also a link? Should the link be inside the label or outside?

  5. #5
    bronze trophy
    Join Date
    Dec 2004
    Location
    Sweden
    Posts
    2,666
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by gnarly
    No, screen-readers don't read the title attribute by default. The label element is where it's at.
    Have you tested?
    Quote Originally Posted by dominique
    Should the link be inside the label or outside?
    I'd say outside. Otherwise if you click the link you also activate the label, which matters if the associated form control is a radio button for instance.
    Simon Pieters

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •