Closed Bug 97774 Opened 18 years ago Closed 18 years ago

ALT text is not displayed in IMG tags or AREA elements


(Core :: Layout, defect, minor)

Windows 98
Not set





(Reporter: georgeb, Assigned: clayton)


From Bugzilla Helper:
User-Agent: Mozilla/4.0 (compatible; MSIE 5.0; Windows 98; DigExt)
BuildID:    2001080110

ALT text for IMG elements is not displayed in the usual manner, neither when 
images are blocked nor when images are displayed. In the second case, the ALT 
text should be displayed as a tooltip.

Reproducible: Always
Steps to Reproduce:
1. Put this code inside an HTML file:
<img src="gif/spacer.gif" usemap="#mymap" width="200" height="200">
<map name="mymap">
<area shape="rect" coords="1,1,100,100" href="javascript: void();" alt="My alt 
<img src="gif/coltar_st.gif" alt="Helloo" width="200" height="200" border=2>
2. Make sure that gif/spacer.gif points to an existing image on your filesystem 
or webserver;
2. Display the file in your Mozilla browser;
3. Try to move the mouse over the image on the right or over the top-left 
corner of the image on the left.
4. Try to disable images or block images from the current site (if you use a 
webserver to deliver this example to your browser)
5. Display the html again.

Actual Results:  When moving the mouse over the image on the right or the 
corner area of the image on the left Mozilla does not display any tooltip 
containing the ALT texts.
When disabling images from the browser preferences or blocking images from the 
current site, Mozilla does not display the alt texts either.

Expected Results:  Mozilla should have displayed tooltips containing the ALT 
text for the IMG and AREA elements when moving the mouse over them.
Mozilla should have displayed the ALT text for the right image after disabling 
image loading or blocking images.
Unfortunately, "the usual manner" is incorrect according to spec.  bug 25537 and
associated bugs have more info.

*** This bug has been marked as a duplicate of 25537 ***
Closed: 18 years ago
Resolution: --- → DUPLICATE
Thanks. I never knew there was a "title" attribute. This works both for Mozilla 
AND for IE. It's not listed in most of the docs tho. Should be more often 
used :)
Verifying dupe.  Reporter: spread the word and it *will* be more often used :)
SPAM. HTML Element component is deprecated, changing to Layout component. See
bug 88132 for details.
Come on Bugzilla, you can do it...
Component: HTML Element → Layout
You need to log in before you can comment on or make changes to this bug.