"Steve Pugh" <st***@pugh.net > a écrit :
| It's always best to put the query in the body of the message as well as
| the subject.
True. So I would like two, vertically centered, blocks on one line: first
block is a fixed-width pixmap, second block is some text of varying length.
| >
http://yo.dan.free.fr/testing/vertically-centered.html
| >
| > I would like to obtain a similar layout as attempt 3 (using a table!).
| [...]
| Here's a demo using background images and display: table
I added your solution to my page (link above) and it looks great! Thanks.
[Well, not uploaded yet at posting time because my web hoster seems down
right now. For one day long now...]
| This was knocked together rather quickly and I'm sure other people will
| be able to improve on it.
So far, pros are:
* simple markup, easy to embed in a <UL>
* seems to work perfectly in modern browsers, and I don't mind if it
is slightly degraded in IE (just enough to say "Aah, should you use
a browser that deserves that name, blah-blah-blah")
Cons are:
* Mozilla 1.7.3 doesn't display short items properly (doesn't honor
min-height!?). That is only a problem if FF also has this problem,
for the advocacy thingy mentionned above ;-).
Neutral:
* Each item has a different icon. What is best practice:
In CSS: LI#topic1 { background-image: url(...) }
In HTML: <LI id="topic1">
- or -
In HTML: <LI style="backgrou nd-image: ...">
Since I feel the icons are more content than presentation/style, I am about
to mix style inside the HTML code, unless you tell me not to do so (I will
abide by anything sprung from ciwas, you see. :o) (for CSS-related questions)
Cheers,
--
Daniel Déchelotte
http://yo.dan.free.fr/