You are here: Re: Need CSS help: displaying items inline (like a Java FlowLayout) « HTML « IT news, forums, messages
Re: Need CSS help: displaying items inline (like a Java FlowLayout)

Posted by Els on 01/12/06 14:49

David Graham wrote:
> "Els" <els.aNOSPAM@tiscali.nl> wrote in message
> news:10gw89ckaxzfe.1efd82rglvqdw$.dlg@40tude.net...
>
>> Here's an example I made 2 years ago:
>> http://locusmeus.com/test/thumbswithcaptionscentered.html
>
> I thought I would put a line of code into the page above to outline the
> tables in white as below:
>
> table{
> width:115px;
> margin-top:0px;
> margin-bottom:0px;
> padding:0px;
> text-align:center;
> display:inline;
> border: 2px solid rgb(255,255,255);
> }
>
> This works as expected in IE6 and Opera 8.51 but in Mozilla 1.7.12 and
> Firefox 1.5 the white outline of the tables is a rectangular box under each
> caption. Rarely does Opera agree with IE6 and disagree with gecko browsers -
> why is Mozilla and Firefox having a hard time with this extra line of code.

IE and Opera each have their own reason: IE because it extends boxes
to encompass their content, and Opera because of "inline-table" (which
is hidden from IE).

> Also, why do you have two inline instructions as the line below
> html>body table { display:inline-table; }
> does the same thing as the next to last line in the table block rule doesn't
> it? Is this child selector thingy only recognised by certain browsers?

The child selector isn't recognized by IE, but the inline-table itself
doesn't do anything in Mozilla. I only added it for Opera.

> thanks in advance for any help you might offer
> just on a learning exercise

Now you know why I didn't make a nice border on the tables ;-)

On a new site I'm working on, I'm having the border I want though, as
the <td> does show a border in the right place in all 3 browsers. I
just tried that technique on the thumbnails page, and found you could
fake a table border by setting the cellspacing to 0, and set borders
on every td, make the border bottom of top td and top border of bottom
td 0. Also added a 1px margin to the tables, to make IE separate them
visually.

Result:
http://locusmeus.com/test/thumbswithcaptionscentered-borders.html

--
Els http://locusmeus.com/
Sonhos vem. Sonhos vão. O resto é imperfeito.
- Renato Russo -
Now playing: Duran Duran - Wild Boys

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация