Re: Empty link



In article <1125335816.347032.178700@xxxxxxxxxxxxxxxxxxxxxxxxxxxx>,
Stanimir Stamenkov <stanio@xxxxxx> wrote:
>/Gus Richter/:
>
>> It would seem that we are asking for mediation on an issue which is
>> regarding an OP asking for:
>> "A method to have a linkable banner image on every page,
>> but without the IMG element coded on every page."
>
>The thing was about not putting anything - using the style*** only,
>but because UAs don't have good (pretty much no) support for generated
>content we have to put something anyway, then let it be appropriate and
>that's what our discussion is about - the appropriateness of the "empty
>link".
>
>> Stanimir's contention is that it is invalid because there is no content
>> in the Anchor.
>
>I didn't say "invalid" - I've said it is bad in the means of not
>appropriate. I've used "invalid" only in my first reply regarding the
>example you've given:
>
><a><div></div></a>
>
>> The other point of contention regarding the below code immediately after
>> BODY (using a transparent image) as:
>>
>> <a href="/index.php"><img id="banner" alt=""
>> src="images/banner_background.gif "/></a>
>>
>> Stanimir says that it is valid.
>
>It is valid in this context free form. That it must be contained in a
>block element in the document to validate against HTML 4 Strict DTD is
>another thing which we don't discuss, but you've involved it, probably
>misinterpreting my words "it's even worse" as "it is not valid". If you
>notice, the examples I've previously given actually wrap the link in a
>DIV element.
>
>Note also my main point is about having image (although just
>transparent) with _not_ empty 'alt' content.
>

Hi

I'm the one who apparently started this.

I wound up recoding my pages to validate agains HTML 4.01 Strict
on the recommendations in this thread. This is my first website, so
I'm learning on the fly, so to speak. I wound up using

<div>
<a href="index.php">
<img id="banner" alt="Home Page Link" src="images/banner_background.gif "/>
</a>
<a name="Top">
</a>
</div>

as the first <div> on each page except for the home page and
everything seems to work as desired and the HTML 4.01 Strict
Validator is happy. Most of my pages are in the same directory,
but I added a relative path for those that are in subdirectories.
I still have a few extra spaces here and there in the code, courtesy
of my text mangler, but I'm gradually dealing with those as I see them.

Thanks all, for the help

Claude

.


Quantcast