RE: [action] rewite example 2 for GL 3.2

I think that the example is wrong. In the GL 2 example 2 said:

<blockquote>
Example 2: a warning is given before displaying a pop-up window. 

At the end of a news story, several links are provided for more information.
At the beginning of each link is an icon of an arrow with the text
equivalent, "Link will open in new window."
</blockquote>

So example is not good for the following reasons:
1. Strict DTDs for HTML and XHTML 1.0 don't contains "target" attribute ( =
no possible to use it with these W3C DTD)
2. The Example can be done only with scripting (removing "target" and using
onclick - onkeypress events)
3. If scripting is not supported, title attribute is not good.

Eventually we should suggest a code like this:

<p>
   Read more about failed elephant evacuation: 
	<a
href="http://www.cnn.com/2005/WORLD/africa/08/25/kenya.elephants.ap/index.ht
ml" 
	   class="targetblank" title="External link">Evacuation Crumbles
Under Jumbo load</a>
</p>

With a script like this one:

function TargetBlank() {
	if(document.getElementsByTagName){
		var msg = " (link opens in new window)";
		var links = document.getElementsByTagName("a");
		for (i = 0; i < links.length; i++) {
			var link = links[i];
			if (link.className.indexOf("targetblank") != -1)
{
				link.title += msg;
				var fn = function () {
				window.open(this.href); return false; }
				link.onclick = link.onkeypress = fn;
			}
		}
	}
}

That via DOM will modify the code as:

<p>
   Read more about failed elephant evacuation: 
	<a
href="http://www.cnn.com/2005/WORLD/africa/08/25/kenya.elephants.ap/index.ht
ml"
	   class="targetblank" 
         title="External link (link opens in new window)" 
         onclick="window.open(this.href); return false;" 
         onkeypress="window.open(this.href); return false;">Evacuation
Crumbles Under Jumbo load</a>
</p>

But is this what we want to suggest?

-----Original Message-----
From: w3c-wai-gl-request@w3.org [mailto:w3c-wai-gl-request@w3.org] On Behalf
Of Gian Sampson-Wild
Sent: Wednesday, August 31, 2005 10:33 AM
To: Becky_Gibson@notesdev.ibm.com; WCAG 
Subject: RE: [action] rewite example 2 for GL 3.2



I think there may be a problem with this example:

<blockquote>
<p>Read more about failed elephant evacuation: <a 
href="http://www.cnn.com/2005/WORLD/africa/08/25/kenya.elephants.ap/inde
x.html" 
target="_blank" title="link opens in new window">Evacuation Crumbles Under 
Jumbo load</a></p>
</blockquote>

I believe it provides information in the TITLE attribute (that the link
opens in a new window) which is (I assume) not provided elsewhere. As Becky
pointed out - this information is not read by Window Eyes or JAWS by default
and therefore this information is not available to one of the groups of
people who need it most.

Cheers,
Gian

-----Original Message-----
From: w3c-wai-gl-request@w3.org [mailto:w3c-wai-gl-request@w3.org] On Behalf
Of Becky_Gibson@notesdev.ibm.com
Sent: Saturday, 27 August 2005 12:53 AM
To: WCAG 
Subject: [action] rewite example 2 for GL 3.2


Action:  update example 2 for GL 3.2 to talk about using title attribute

on link
Proposal:  remove example 2 (as was the general consensus in the poll [1] 
and at the August 25, 2005 meeting) and update HTML Technique 9.2

Details:
At the August 25, 2005, teleconference I took an action item to propose a 
new example 2 for GL 3.2 that would talk about using the title attribute

to indicate that a link opens in a new window.  After more research I am

willing to remove this example since I think the use of the title 
attribute on a link is better represented as a technique.   Using a
title 
will display a tooltip on mouse over of the link, which is helpful. But, 
the JAWS and WindowEyes screen readers do not speak titles on links by 
default so I'm not sure it is a good example to use.    I do believe
that 
adding a title attribute on a link to indicate that it opens in a new 
window does meet GL 3.2 L1 SC1, Any change of context is implemented in a 
manner that can be programmatically determined. [2].  Thus, I would 
propose updating the HTML Technique 9.2, Supplement link text with the 
title attribute [3], to include information about using the title to 
indicate a new window and reference GL 3.2 L1 SC1 as well as the current

reference to GL 2.4 L2 SC4. 

Example:
<p>Read more about failed elephant evacuation: <a 
href="http://www.cnn.com/2005/WORLD/africa/08/25/kenya.elephants.ap/inde
x.html" 
target="_blank" title="link opens in new window">Evacuation Crumbles Under 
Jumbo load</a></p>

This is only viable in HTML 4.01 (because target attribute is removed in

XHTML 1.0 strict)  but could also be included in an example for a 
scripting technique about creating links that open in a new window. 


[1] http://www.w3.org/2002/09/wbs/35422/consistent-behavior0822/results
[2] http://www.w3.org/TR/WCAG20/#id4517016
[3] http://www.w3.org/TR/WCAG20-HTML-TECHS/#a-title

Becky Gibson
Web Accessibility Architect
                                                       
IBM Emerging Internet Technologies
5 Technology Park Drive
Westford, MA 01886
Voice: 978 399-6101; t/l 333-6101
Email: gibsonb@us.ibm.com

Received on Wednesday, 31 August 2005 10:02:28 UTC