XHTML validation

Associate
Joined
2 Aug 2005
Posts
680
I've just run a watchfire validation on a site that I am building and I've come across a little problem. Is this sort of code ok?

<div id="buttonspacel"></div>
<a href="../index.php" id="button1" title="Home"></a>
<a href="../retro.php" id="button2" title="Retro"></a>

...and a list of other links to main sections of the site. These links are stored inside a div and all links are pictures as defined in my CSS. This is failing the watchfire under "3.1 Create link phrases that make sense when read out of context.". Does anyone know a good way for me to fix this?

Any advice appreciated.
 
It's specified in my CSS as

#buttonspacel,#buttonspacer {
width:12px;
}

and

#buttonspacel { background-image:url(images/buttonspacel6.gif); }

It's basically to make my html code only information and keep all formatting and style information in the style sheet. Do you know how I can get the A tags to validate?
 
Unless maybe I setup an aural stylesheet and enabled the text. It sounds easier to go with the indent option though. Thanks everyone :)
 
I've got a set of rollover buttons at the bottom of the page, and the whole site has a 10px margin around it. The spacers just seperate the buttons from the side. I did this because the buttons are the same graphics on every page but the background changes, so the style for the buttonspace is set in the head of the html. Is there another way I could do this?

You mentioned the menu, do you mean set it up as a list with display:inline; ?
 
Last edited:
Back
Top Bottom