Author Archive

HTML5 has reached Last Call status – submit feedback until August 3

On 25 May the W3C posted W3C Invites Broad Review of HTML5, announcing that the HTML5 specification is now at Last Call and that broad review is welcome until August 3, 2011.

In practice this means that anyone is welcome to submit their feedback on the HTML5 specification and a number of related specifications. That’s kind of always been the case since participation in the HTML Working Group is open for all. But now the spec is stable enough for people who don’t actively participate in the standards process to review and comment.

Read full post

Posted in , .

Copyright © Roger Johansson



Styling ordered list numbers

I’ve always been annoyed by how difficult it is to style the numbers of ordered lists. Quite often a design calls for something other than just a plain figure – a different font, size, colour, background, whatever.

The traditional approach to solving this problem has been to prevent the browser from rendering the numbers of the list items (li elements) and instead hard code the numbers in the text content of the li. That makes it possible to add styling hooks to the number and style away until you’re happy.

Doing it that way works visually, but it isn’t exactly a semantically correct way of using lists. When you view a faked numbered list with CSS disabled you see either a list with the item numbers repeated or a list with bullets and numbers, and that feels backwards to me. I wanted to find a better way.

Read full post

Posted in .

Copyright © Roger Johansson



Do unobtrusive, accessible social media sharing widgets exist?

Many clients are still asking for various bookmarking widgets for social media. You know, the kind that shows a bunch of icons for Twitter, Facebook, email, etc. Two popular examples are ShareThis and AddThis, but there are others.

What bugs me with every social media sharing widget I have looked at is that they are not very keyboard friendly, i.e. they are difficult or even impossible to use without a mouse. They also tend to use invalid, obtrusive markup.

Read full post

Posted in .

Copyright © Roger Johansson



Accessibility checklists can be helpful if used right

It is sometimes argued that using checklists when implementing or evaluating accessibility will lead to “checklist accessibility�, where developers blindly follow a checklist and do what they have to do to be able to check each item off the list without understanding why.

I agree that in the wrong hands, checklists can be used incorrectly. But I don’t see how you get from there to all forms of accessibility checklists being harmful. When constructed and used correctly by people who understand why the items on the list are important, checklists can be a great help to both developers and evaluators.

Read full post

Posted in , .

Copyright © Roger Johansson



Get element text, including alt text for images, with JavaScript

Sometimes I find myself wanting to get the text contents of an element and its descendants. There is a DOM method called textContent that can be used for this. There is also jQuery’s text() method. Unfortunately neither method returns what I want.

In both cases, elements that can have alt attributes are omitted from the returned string. In my opinion, alt text is the text content of an img, input[type=image] or area element and should be returned by methods like these. I also find it a bit weird that they return the contents of script elements.

Not having any luck finding a method that includes alternative text and omits script elements when getting text content, I wrote my own.

Read full post

Posted in .

Copyright © Roger Johansson



  •   
  • Copyright © 1996-2010 BlogmyQuery - BMQ. All rights reserved.
    iDream theme by Templates Next | Powered by WordPress