Please validate the files at: http://validator.w3.org/
1) Charset. UTF-8 is formally the default. At different times/versions it is or is not
required. At this time the validator is looking for it. The XML version stays as is,
add the encoding and the meta tag.
When you validate, the validator likes to get held up on charset. What this means
is that you are declaring what language your site is in. The browser picks the
charset up and knows what language and with what characters it should output.
UTF-8 is the code for American English, which from a code perspective, is
different than UK English. There are codes for all written languages. To pass this
portion of validation, change your XML declaration to:
<?xml version="1.0" encoding="UTF-8"?>
and add the following meta tag within your head element.
<title>Demonstration-whatever your title says is
2) In Quick Tips 1 I referred to the alt tag. alt is actually an attribute, although
we call it a tag. Its purpose is to provide a label for an image so that a sight
impaired person seeing this:
Will “hear” this
“oversized chocolate cupcake with white and purple sprinkles”
On their audio output device or read it on their braille-based keyboard.
The code should be
It resides in your image element
<img height="53" width="15" src="images/cupcake.gif" alt=" oversized
chocolate cupcake with white and purple sprinkles " />
3) target= "_blank " doesn’t validate, what’s up?
Ok. There is so much to learn. You will primarily use two DTDs. Strict and
Transitional. For this class we use strict because you need to learn how to do this
right. Transitional is a little looser. In addition, next week we will learn
accessibility which has primarily three levels, each has a slightly more rigorous
set of standards. So, this leaves you with typically two DTDs and, most often, two
levels of accessibility to deal with.
The fundamental problem with target= "_blank " is if you are using a Braille-
based user agent or are listening to a website due to impaired vision, you can get
so many windows opened up you can’t find your way through a site. For non
vision-impaired users, we tend to close windows rather than use the browser’s
back button and it’s easy to lose clients because they don’t want to start from
scratch and go all the way back to that page in your site again.
For now, let’s either take out or ignore the target attribute. In the next lessons on
accessibility we will work with the different DTDs and levels of accessibility. And
then later in the class I’ll show you how to do breadcrumbs to enable a person to
get back into a site where they left off.