Re: Style Sheet Equiv Question

by "Darrell King" <darrell(at)webctr.com>

 Date:  Sat, 9 Mar 2002 18:58:32 -0500
 To:  "HWG Techniques" <hwg-techniques(at)hwg.org>
 References:  computer zydhek1
  todo: View Thread, Original
Margin would seem to be more useful, as it puts space between the border and
the surrounding elements...?

D


----- Original Message -----
From: "Kehvan M. Zydhek" <kehvan(at)zydhek.net>


> ...(An image can't have padding.)...

Who says? I'm working on a site right now where I have some images floated
left or right AND have padding around them (so the text doesn't bunch up on
them), all set with INLINE styles (in the IMG tag), and the Homesite and W3C
XHTML validators have absolutely no problem with this. An image (and any
other element) CAN have padding. It's possible and extremely useful. Here's
a sample IMG tag that validates:

<.img src="(image)" alt="Image 1" style="width: 75px; height: 100px;
padding: 0px 5px 5px 5px; float: right;" />

Since it validates, then I would say that images CAN have padding. ;-)

HWG hwg-techniques mailing list archives, maintained by Webmasters @ IWA