469,579 Members | 1,899 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,579 developers. It's quick & easy.

Mozilla / (Geko ?) test and "display: -moz-inline-box"

Hi,

I want an "isZZZ" variable that I can use to generate
"display: -moz-inline-box;" rather than "display: inline-block;" but in DOM.

For this I need to know what version of Mozilla this "feature" was added and
also how to detect Mozilla as a userAgent.

Alternatively is there an alternative to "display: -moz-inline-box" for
sticking two tables side by side ?

Many thanks in advance,

Aaron
Jan 4 '07 #1
4 2775
"Aaron Gray" <an********@gmail.comwrote:
>I want an "isZZZ" variable that I can use to generate
"display: -moz-inline-box;" rather than "display: inline-block;" but in DOM.

For this I need to know what version of Mozilla this "feature" was added and
also how to detect Mozilla as a userAgent.

Alternatively is there an alternative to "display: -moz-inline-box" for
sticking two tables side by side ?
I'd code a cross browser solution and forget about UA sniffing.

The correct CSS value to use is "inline-table", unfortunately like
"inline-block", "inline-table" is another long standing deficiency in
Mozilla's CSS support. (I'm guessing there's something in Mozilla's core
code that prevents such from working)

I'd suggest never to use "-moz-inline-block" for anything as the result
is terrible, nothing like "inline-block".

The following works in IE, Mozilla and Opera if you don't use a border
around the table element and if you are not fussy about vertical-align:

yourvarname.style.display = 'inline';
yourvarname.style.display = 'inline-table';

--
Spartanicus
Jan 4 '07 #2
I used :-

table.style.display = "inline";

in the end. Seems to work fine.

Could not seem to get DOM to work with styles and classes at all.

Aaron
Jan 4 '07 #3
"Aaron Gray" <an********@gmail.comwrote:
table.style.display = "inline";

in the end. Seems to work fine.
They say that ignorance is bliss.
>Could not seem to get DOM to work with styles and classes at all.
We can't help if you don't show us the problem.

--
Spartanicus
Jan 4 '07 #4
"Spartanicus" <in*****@invalid.invalidwrote in message
news:le********************************@4ax.com...
"Aaron Gray" <an********@gmail.comwrote:
> table.style.display = "inline";

in the end. Seems to work fine.

They say that ignorance is bliss.
>>Could not seem to get DOM to work with styles and classes at all.

We can't help if you don't show us the problem.
No, I have avoided the prolem for now. The project is pre-alpha at the
moment, but I suppose I could given an example. Sorry. I may do when I get
some more time.

Thanks for your help,

Aaron
Jan 5 '07 #5

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

reply views Thread by Ola Natvig | last post: by
6 posts views Thread by David List | last post: by
10 posts views Thread by tony kulik | last post: by
3 posts views Thread by Mr. x | last post: by
reply views Thread by Felix Natter | last post: by
11 posts views Thread by dhplank | last post: by
8 posts views Thread by Clément | last post: by
2 posts views Thread by Netkiller | last post: by
reply views Thread by suresh191 | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.