forrest-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Qin Ding <>
Subject Re: alt="top" in img element (was Re: )
Date Tue, 30 Aug 2005 19:06:21 GMT
Thank you, Ross, for your help.


This is a PRIVATE message. If you are not the intended recipient, please 
delete without copying and kindly advise us by e-mail of the mistake in 
delivery. NOTE: Regardless of content, this e-mail shall not operate to 
bind CSC to any order or other contract unless pursuant to explicit 
written agreement or government initiative expressly permitting the use of 
e-mail for such purpose.

Ross Gardler <rgardler>
08/30/2005 12:44 PM
Please respond to user
        Subject:        alt="top" in img element (was Re: )

(please using meaningful subject lines in your emails)

Qin Ding wrote:
> When I tried to use align="top" attribute in img element for xdocs xml 
> (ie <img src="../../images/1920.gif" width="155" height="81" ALIGN="TOP" 

> alt="1920s image"/>, I got the invalid error: Attribute "ALIGN" must be 
> declared for element type "img". [49].

It doesn't validate because it is not allowed in our DTD. See

The reason it is not allows is because this is layout information and 
should not be part of the source document but part of the CSS describing 
the layout.

To achieve what you want you will have to give your img element a class 
like this:

<img src="../../images/1920.gif" width="155" height="81"
alt="1920s image" class="topAligned"/>

Then in your skinconf.xml file add this class to the extra-css element, 
defining it as you require, for example:

img.topAligned { vertical-align:text-top }

For reference materials on CSS see


View raw message