Passing Validation

M

Mohawk Mawk

I can't pass the W3C Validation because it wants to compromise my
sites functionality.
Here is the problem
Site: http://bjorntoday.com/?page=Imprint&lang=E
Validation:
http://validator.w3.org/check?uri=h...charset=(detect+automatically)&doctype=Inline
I have 9 errors
one is the <marquee> Tag error, never mind that.
the other 8 are due to the fact that a <div>, can't be in the <a>
tag??
whats up with that?
the reason i need the <div> tag to be in <a> is so that i can click
the div to open a url.
e.g.
See the flags on top of the page? The British and the German.
This is the HTML
<a href="?page=Imprint&lang=E"><div id="langE"><span>English</span></
div></a>
This is the CSS
#langE{
background: transparent url(images/e.jpg) no-repeat top left;
width: 30px;
height: 15px;
}
#langE span{display:none;}

Now i know i could just insert an <img> tag but I won't do that
because the site must be visually changeable via css.

Other problem are the rollover buttons.
<a href="?page=GuestBook&amp;lang=E"><div class="link">Guestbook</
div></a>
the <div> is there so the surface around the actual text is clickable.

Is there hope for me? or will the page just never pass? (excluding the
marquee tag)

bless
mawk
 
A

Adrienne Boswell

Gazing into my crystal ball I observed Mohawk Mawk
<[email protected]> writing in


I can't pass this up, folks!
I can't pass the W3C Validation because it wants to compromise my
sites functionality.

I don't think the validator wants to compromise your site's
functionality, unless there's some conspiracy no one let me in on.
Here is the problem
Site: http://bjorntoday.com/?page=Imprint&lang=E
Validation:
http://validator.w3.org/check?uri=http://bjorntoday.com/?page
%3DImprint%26lang%3DE&charset=%28detect+automatically%29&doctype=Inline
I have 9 errors
one is the <marquee> Tag error, never mind that.

I hope you're getting rid of that. If the information is imporant, why
would you want visitors have to wait for the message to come back round?
Marquees and other moving text are distracting for the user and a PITA.
the other 8 are due to the fact that a <div>, can't be in the <a>
tag??
whats up with that?

An inline element cannot contain a block element. Simple.
the reason i need the <div> tag to be in <a> is so that i can click
the div to open a url.

What's wrong with clicking on the a element itself? That's what it's
there for.
e.g.
See the flags on top of the page? The British and the German.
This is the HTML
<a href="?page=Imprint&lang=E"><div id="langE"><span>English</span></
div></a>
This is the CSS
#langE{
background: transparent url(images/e.jpg) no-repeat top left;
width: 30px;
height: 15px;
}
#langE span{display:none;}

Then style the a element itself. Don't put an unnecessary element in
there. What? Do you have Divitis?
Now i know i could just insert an <img> tag but I won't do that
because the site must be visually changeable via css.

Other problem are the rollover buttons.
<a href="?page=GuestBook&amp;lang=E"><div class="link">Guestbook</
div></a>
the <div> is there so the surface around the actual text is clickable.

Style the a element.
Is there hope for me? or will the page just never pass? (excluding the
marquee tag)

I think you need to get to the nearest ER because you definately have
Divitis. There is a cure - use semantic markup.
 
C

Chris F.A. Johnson

ok
1. the marquee tag will be gone, its just a placeholder.

What marquee tag?

This is Usenet, not Google Groups. Please quote enough relevant
material so that people know what you are talking about.
2. the a element is a inline element and has no surface like a block
element mister smarty pants.

You can make it a block element with CSS (though I doubt that
that's necessary).
just so you can see what i mean i have uped the new code
http://bjorntoday.com/?page=Imprint&lang=E
notice any difference between the "Picture Blog" and "Picture Archive"
buttons?

No. There is none.
HTML
<td><a href="?page=Home&amp;lang=E" class="link">Picture Blog</a></
td>
<td><a href="?page=Gallery&amp;lang=E"><div class="link">Picture
Archive</div></a></td>
CSS
.link{width:100%;height:100%; }

Why are you using a table for non-tabular material?
the "Picture Blog" button is only clickable on the text, even though
it has the same class as the DIV, witch is fully clickable around the
text.

and that is why i need a block element like div in an inline element

Please explain what you want. It's not clear from your post or your
web page.
why should this cause an error in the validation?

It's like wearing your shoes inside your socks.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,995
Messages
2,570,228
Members
46,817
Latest member
AdalbertoT

Latest Threads

Top