Happy is he who has overcome his ego... who has attained peace... who has found truthGautama Buddha
Also relates to Web Standards
In follow up to Andrew Sinclair's Accessibility Article I had a quick reccie of the Anglia Railways website, mentioned in the article for its recent receipt of the RNIB See It Right logo.
The W3C Validator failed the home page with 80 errors, many of which were associated with incorrect embedding of Flash objects in the page and entity errors in URL query strings, but also failure to close a few elements.
Bobby (an official part of the
RNIB audit) was equally less forgiving, picking up on absolute sizing at Level 2. Cynthia was equally unhappy with the use of the deprecated embed element. View the page in Mozilla and there is an immediate problem with the on and return labels. Blow
up the text 2 times and the page quickly become difficult to view.
So, what exactly does the RNIB See It Right campaign represent? Perhaps the Anglia Railways site passed the audit a week ago, but has changed since then. Or perhaps a few important accessibility issues are brushed under the table as not relevant to this specific audit - the errors are perhaps not relevant for screen readers and braille browsers? Well clearly, valid and well formed markup is of little importance, with the Audit guidelines page failing to supply a DOCTYPE!
Posted on Sep 19, 2003 at 13:31:52. [Comments for Does RNIB See It Right?- 1]
Also relates to DOM Scripting and Firefox and Co
On a current project, where accessibility is essential, I have integrated a stylesheet switcher on two pages where a mouseover affect on an image montage displays an introduction to each page in a separate box below the montage. The montage is structurally defined as a definition list, since it is a visual representation of links to pages on the site, with a brief description of each page. The stylesheet switcher allows users to switch the view to an actual list representation, if, for example, they are using only the keyboard. For CSS-enabled browsers without Javascript, the switcher loads a fresh page with the list display, and for non-display browsers the montage is just represented as a list from the outset.
While, I hope this will be effective under most conditions, I found a frustrating problem with supplementing
the onclick event with an onkeypress event for keyboard users in Mozilla and co.
When tabbing through the links on the page, as soon as the user tabs off the switcher (containing the event handler)
the key press event is triggered. Well, of course, this is the correct behaviour, but Inte$net Exploder actually only
triggers the event when the Return key is pressed, which is misleading to the developer, and incorrect interpretation.
The solution was to integrate a filter function that is called by the onkeypress event and this in turn only
calls the style switcher function if the key pressed was Return
Here is the code:
function checkKeyPressed(evt, func, params)
{
evt = (evt) ? evt : (window.event) ? event : null;
if (evt)
{
var charCode = (evt.charCode) ? evt.charCode :
((evt.keyCode) ? evt.keyCode :
((evt.which) ? evt.which : 0));
if (charCode == 13) func(params);
}
}
Where 13 is the ASCII value for the Return key. As well as passing the event as argument, I passed the function to be called and its parameters, to make the function generic. The scenario is just as relevant if using the event handlers to open a new window from a link (although this is strongly discouraged). The resulting anchor is as follows:
<a href="#" onclick="setStyleSheet('sheet'); return false;"
onkeypress="checkKeyPressed(event, setStyleSheet, 'sheet');"
>Switch to List View</a>
It is important that a false value is not returned in the key press event since this would prevent the user from tabbing beyond the style switcher link. The DHTML cookbook suggests the key detection in the filter should work in Netscape and Exploder back to v.4. It resolved the issue for this project.
Posted on Sep 14, 2003 at 16:44:31. [Comments for Key Press Event Handling- 7]
Also relates to Web Standards and CSS Design
Ok, yet another FIR technique has been created by Levin Alexander to resolve the inherent problem
for CSS enabled browsers with images disabled. While this solution does display the header in plain text when images are disabled, it falls foul of reintroducing a span element, which the techniques of Stuart Langridge and Seamus Leahy had
tried to resolve. While this new approach makes nice use of the relative→absolute relationship between parent and child in CSS positioning, it fails with transparent PNG (or GIF) header graphics, and for any design with coloured background,
transparency is a prerequisite to avoid visual discrepancy between the browser interpretation of the color and that defined in the image file.
Determined to resolve this, I tried changing visibility, third dimension placement (z-index) and container heights, but there is always going to be one scenario that breaks the hack. Since FIR and its many derivatives are just that, a hack, I have come to the conclusion that FIR by itself cannot succeed as an Accessibility tool. It does present an excellent method for separating design and content, implementing alternative graphics with each stylesheet, and fortifying the semantics of the XHTML document's markup. But once accessibility is contemplated, other methods must also be introduced to present each user with the same material. The obvious way to acheive this is to use a Stylesheet Switcher to offer a plain text version of the page. Here I am not talking about the plain text of 90's websites, where the content of the site must be completely duplicated in the appropriate format. With the tools of the DOM the same XHTML marked-up page can be used, and a simple alternative stylesheet created to display plain text for the entire site.
So the graphic design version of the site can implement a FIR technique to ensure the content does not contain superfluous code. For example a header would be just a header.
<h1 id="header">This is the page header</h1>
And the stylesheet would implement FIR to replace the text with the graphic. This can offer an accessible page to most users. For the neglected few, switching to the plain text style sheet presents the header as is (there are simply no FIR techniques declared). Hence, users browsing with CSS enabled browsers with images disabled can also access all the material. Everyone is happy!?
Well there is still the possibility of a user with CSS-enabled browser, no images and no Javascript! Then what? Fall back to server-side scripting perhaps, with a GET string appended to a URI in the Stylesheet Switcher anchor when it is loaded (using the noscript tag). Then
the correct stylesheet for the pulled page can be set as default before the page is sent to the client.
Posted on Aug 18, 2003 at 19:00:46. [Comments for FIR, Accepted Defeat!- 0]
Also relates to PHP and Peregrinations
Been very busy the past couple of weeks, so not much time for blogging…Here's a few bits and pieces from around the web…
Posted on Aug 17, 2003 at 21:20:43. [Comments for A Few Quick TitBits- 0]
Also relates to Web Standards
A bit of blogging lethargy recently, after returning from a week's holiday in rainy old St Ives. Admittedly, work has kept me away from the more pleasurable side of the web through the last few days. Seems to have been lots going on in my time away, but with time currently short and sweet, I will fire off this post in similar vain.
Just really want to have a little rant about where things are (or are not) going in the realm of Accessibility. Just picked up on the formation of the EuroAccessibility Consortium from the (still below par) RNIB Press Centre. So, I though I'd delve a little deeper and had a look at the towers of strength that would be representing Ol Blighty in this very justified initiative.
Well the RNIB rebuild has already been documented extensively, but I decided to have a quick reccie of the other sites, since they must surely represent pillars in the Accessibility community.
Didn't get very far since I got held up on the first page of the Access in Mind website. There are a number of very useful accessibility tools in Opera 7 which I enjoy running over numerous sites I visit around the web.
At this point, the testing ground to a halt and I fired up my blogger. Ok, it can be argued there is the base menu to cover the failure in Test Two, but once the text is enlarged, this menu is not visible without scrolling, leaving no navigation readily available on screen. This hardly RNIB See it Right certifiable.
Another quirk is the one-pixel defined skip navigation container visible in top left of screen. I am guessing this has probably been used to avoid JAWS missing it if declared display:none in the style sheet. But wait a minute….Doesn't CSS define alternative media types??? Surely this container could be hidden on screen media, while made accessible on a separate aural stylesheet. Alas, the AiM
CSS file doesn't do it many more favours, with a lot of repetitious and redundant declarations. Again, maybe an accessibility guru would turn around and say these rules and this layout is necessary to support Screen Readers or Braille browsers, as has
occurred in the RNIB debate over recent months. But it is this very thought that stirred a rant in me.
I feel this approach to accessibility is not resolving the issue, but simply turning it on it's head. Building websites for less-abled users at the expense of all other users. This is certainly not what the WAI and Web Standards is all about. The tools are readily available now to make a site that is accessible to all, offering the benefits to each user based on the agent they have chosen to use, or the abilities they have. Sometimes workarounds are required for more complex design issues, but this doesn't mean the basics should be ignored. While clearly important, blind, deaf and visually impaired users are not the only demographic that accessibility addresses. What about portables, low bandwidth users, text users, legacy users etc etc….?
Phew, I have had my say….
Posted on Jul 31, 2003 at 18:46:14. [Comments for A Rant On Accessibility- 0]