CSS equivalents for attributes | | |
There's a number of elements that I set attributes for:
<table border="1" cellpadding="3" cellspacing="0">..
<img align="middle">
Are there CSS equivalents for any of these?
Jeff | | | | re: CSS equivalents for attributes | | | | re: CSS equivalents for attributes
Jeff Thies wrote:
[color=blue]
> There's a number of elements that I set attributes for:
>
> <table border="1" cellpadding="3" cellspacing="0">..
>
> <img align="middle">
>
> Are there CSS equivalents for any of these?
>
> Jeff[/color]
<table style="border:1px #FFFFFF; padding:3px; margin:0px;">
<div syle="text-align:center"><img src="" alt="" /></div>
--
x theSpaceGirl (miranda)
# lead designer @ http://www.dhnewmedia.com #
# remove NO SPAM to email, or use form on website # | | | | re: CSS equivalents for attributes
SpaceGirl wrote:
[color=blue]
> Jeff Thies wrote:
>[color=green]
>> There's a number of elements that I set attributes for:
>>
>> <table border="1" cellpadding="3" cellspacing="0">..
>>
>> <img align="middle">
>>
>> Are there CSS equivalents for any of these?
>>
>> Jeff[/color]
>
>
> <table style="border:1px #FFFFFF; padding:3px; margin:0px;">
>
> <div syle="text-align:center"><img src="" alt="" /></div>
>
>[/color]
oops: <table style="border:1px solid #FFFFFF; padding:3px; margin:0px;">
--
x theSpaceGirl (miranda)
# lead designer @ http://www.dhnewmedia.com #
# remove NO SPAM to email, or use form on website # | | | | re: CSS equivalents for attributes
Jeff Thies <jeff@spamalanadingong.com> writes:[color=blue]
> There's a number of elements that I set attributes for:
>
> <table border="1" cellpadding="3" cellspacing="0">..
>
> <img align="middle">
>
> Are there CSS equivalents for any of these?[/color]
Yes. border, padding, border-spacing and vertical-align. http://www.w3.org/TR/CSS2/
--
Chris | | | | re: CSS equivalents for attributes
SpaceGirl <NOspaceSPAMgirl@subhuman.net> writes:[color=blue]
> Jeff Thies wrote:[color=green]
> > There's a number of elements that I set attributes for:
> > <table border="1" cellpadding="3" cellspacing="0">..
> > <img align="middle">
> > Are there CSS equivalents for any of these?
> > Jeff[/color]
>
> <table style="border:1px #FFFFFF; padding:3px; margin:0px;">[/color]
Not quite - cellspacing is duplicated in CSS by border-spacing, not
margin (and even then only if border-collapse: separate is set).
And the padding should be on the tds, not on the table itself, to
duplicate the old cellpadding effect.
[color=blue]
> <div syle="text-align:center"><img src="" alt="" /></div>[/color]
And 'align="middle"' on an image is vertical not horizontal alignment.
--
Chris | | | | re: CSS equivalents for attributes
<snip>[color=blue][color=green][color=darkred]
>>>Are there CSS equivalents for any of these?
>>> Jeff[/color]
>>
>><table style="border:1px #FFFFFF; padding:3px; margin:0px;">[/color]
>
>
> Not quite - cellspacing is duplicated in CSS by border-spacing, not
> margin (and even then only if border-collapse: separate is set).[/color]
That is the most complicated bit of CSS I've ever seen:
<URL: http://www.w3.org/TR/CSS2/tables.html >
What's the level of support for this? I'd hate to spend a day wading
through that and finding out the support is limited.
What's with this inline-table (that sounded easy)? I'm assuming this is
display: inline rather than display: block, but I don't have a clue how
to set that! Or is that it?
Maybe it'll make more sense after I've had more sleep, but I'm not so sure.
Jeff
[color=blue]
>
> And the padding should be on the tds, not on the table itself, to
> duplicate the old cellpadding effect.
>
>[color=green]
>><div syle="text-align:center"><img src="" alt="" /></div>[/color][/color] | | | | re: CSS equivalents for attributes
Jeff Thies <jeff@spamalanadingong.com> writes:[color=blue]
> <snip>[color=green][color=darkred]
> >>>Are there CSS equivalents for any of these?
> >>> Jeff
> >>
> >><table style="border:1px #FFFFFF; padding:3px; margin:0px;">[/color]
> > Not quite - cellspacing is duplicated in CSS by border-spacing, not
> > margin (and even then only if border-collapse: separate is set).[/color]
>
> That is the most complicated bit of CSS I've ever seen:
>
> <URL: http://www.w3.org/TR/CSS2/tables.html >
>
> What's the level of support for this? I'd hate to spend a day wading
> through that and finding out the support is limited.[/color]
Support is good. And once you've used it once it won't seem
complicated.
<table cellspacing="5" cellpadding="3" border="1">
to
<table class="styled">
table.styled {
border-spacing: 5px;
border-collapse: separate;
border: thin black solid;
}
table.styled td {
padding: 3px;
}
isn't too difficult.
Probably you'd be better in most cases taking advantage of CSS's
ability to set padding/spacing in em rather than px.
[color=blue]
> What's with this inline-table (that sounded easy)? I'm assuming this
> is display: inline rather than display: block, but I don't have a clue
> how to set that! Or is that it?[/color]
table {
display: inline-table;
}
Easy. Less well-supported than the rest. I've never needed to use it,
though.
--
Chris | | | | re: CSS equivalents for attributes
"SpaceGirl" <NOspaceSPAMgirl@subhuman.net> a écrit dans le message de
news:2lhvjqFd49pvU2@uni-berlin.de[color=blue][color=green]
>> <table border="1" cellpadding="3" cellspacing="0">..[/color][/color]
(...)[color=blue][color=green]
>> Are there CSS equivalents for any of these?[/color][/color]
[color=blue]
> <table style="border:1px #FFFFFF; padding:3px; margin:0px;">[/color]
I don't think the border="1" would be exactly reproduce by your border:1px
#FFFFFF; : this will just add a border around the table, not around each of
the cells... | | | | re: CSS equivalents for attributes
Jeff Thies wrote:[color=blue]
> There's a number of elements that I set attributes for:
>
> <table border="1" cellpadding="3" cellspacing="0">..
>
> <img align="middle">
>
> Are there CSS equivalents for any of these?
>
> Jeff[/color]
table {border: 1px solid black; border-spacing: 0px;}
td, th {padding: 3px;}
img {vertical-align: middle;}
Note that MSIE 5.x and MSIE 6 do not support border-spacing. So, until
the next upcoming MSIE 7 fixes that, you should either use
cellspacing="0" or add the declaration border-collapse: collapse; to
your CSS rule (for table) if you want to collapse borders.
DU | | | | re: CSS equivalents for attributes
Stan Brown wrote:
[color=blue][color=green]
>>oops: <table style="border:1px solid #FFFFFF; padding:3px; margin:0px;">[/color]
>
>
> oops: "0px" is unnecessary; use "0".
>
> oops: #FFFFFF is white. I think you want #000 if you're trying to
> match <table> attributes.
>
> The bigger issue is that probably padding should be in ems not
> pixels. Otherwise, why use CSS at all when the <table> tag is
> already the way he wants?[/color]
Yes I know what colour white is thank you. And the px *might* be
unrequired for zero values, but it's better than missing them off for
possive / negative values :) The OP was an obvious newbie, so I was
trying to make it easier...
--
x theSpaceGirl (miranda)
# lead designer @ http://www.dhnewmedia.com #
# remove NO SPAM to email, or use form on website # | | | | re: CSS equivalents for attributes
Stan Brown wrote:
[color=blue]
> oops: "0px" is unnecessary; use "0".[/color]
The specifications clearly state that units are _optional_ when a zero
value is given. I'm sure you know the meaning of the word "optional" and
understand that it is not incorrect to specify units in a zero case.
--
Dylan Parry http://www.webpageworkshop.co.uk - FREE Web tutorials and references
Now playing: King Crimson - Discipline | | | | re: CSS equivalents for attributes
Stan Brown wrote:
[color=blue]
> "SpaceGirl" <NOspaceSPAMgirl@subhuman.net> wrote in
> comp.infosystems. www.authoring.stylesheets:
>[color=green][color=darkred]
>>><table style="border:1px #FFFFFF; padding:3px; margin:0px;">[/color]
>>
>>oops: <table style="border:1px solid #FFFFFF; padding:3px; margin:0px;">[/color]
>
>
> oops: "0px" is unnecessary; use "0".
>[/color]
The "px" in "0px" might be unnecessary but for 2 reasons I would
recommend to add it even in such case:
1- readers of this post (not fully aware of strict error conditions in
CSS1) might think that "px" is optional and not adding it works anyway
in MSIE 5.x and MSIE 6 in backward compatible rendering mode. The truth
is that writing "px" is *only* optional for zero-length value. You can't
be wrong - whatever the browser, whatever the browser version, whatever
the rendering mode - if you always mention the length unit.
2- if you ever or later change the value from 0px to, say, 4px, then the
px string is already written. So, you won't forget to add it and you
won't need to write it. This is a good coding practice to adopt, just
like using curly braces even for single instruction.
DU
[color=blue]
> oops: #FFFFFF is white. I think you want #000 if you're trying to
> match <table> attributes.
>
> The bigger issue is that probably padding should be in ems not
> pixels. Otherwise, why use CSS at all when the <table> tag is
> already the way he wants?
>[/color] | | | | re: CSS equivalents for attributes
On Tue, 13 Jul 2004 10:09:22 -0400, DU <drunclear@hotWIPETHISmail.com>
wrote:
[color=blue]
> 2- if you ever or later change the value from 0px to, say, 4px, then the
> px string is already written. So, you won't forget to add it and you
> won't need to write it. This is a good coding practice to adopt, just
> like using curly braces even for single instruction.[/color]
When may we omit the curly braces around a style rule again?
Did you mean the semicolon? | | | | re: CSS equivalents for attributes
Neal wrote:
[color=blue]
> When may we omit the curly braces around a style rule again?[/color]
When used inline ;)
[color=blue]
> Did you mean the semicolon?[/color]
I'm sure he did.
--
Dylan Parry http://www.webpageworkshop.co.uk - FREE Web tutorials and references
Now playing: Emerson, Lake and Palmer - Tank | | | | re: CSS equivalents for attributes
Neal wrote:
[color=blue]
> On Tue, 13 Jul 2004 10:09:22 -0400, DU <drunclear@hotWIPETHISmail.com>
> wrote:
>
>[color=green]
>> 2- if you ever or later change the value from 0px to, say, 4px, then
>> the px string is already written. So, you won't forget to add it and
>> you won't need to write it. This is a good coding practice to adopt,
>> just like using curly braces even for single instruction.[/color]
>
>
> When may we omit the curly braces around a style rule again?
>
> Did you mean the semicolon?[/color]
No. I meant the controlled statement of a if instruction. Sorry if I was
not clear in my post (re-edited in a hurry). E.g.:
1)
if(boolean condition)
single statement
is a perfectly correct javascript instruction. And
2)
if(boolean condition)
{ single statement };
is also a perfectly correct javascript instruction.
The 2) example is a much better coding pratice. If I ever need to add
another statement, then the block code delimeters are already written.
If I don't ever need to add another statement, then the curly braces
help code readability.
Semi-colon are also another example of good coding practices: they help
code readability everywhere applicable as syntaxical separators in
javascript for statements and in stylesheets for CSS declarations.
DU | | | | re: CSS equivalents for attributes
"Jeff Thies" <jeff@spamalanadingong.com> wrote in message
news:BEPIc.6982$kK.3273@newsread3.news.atl.earthli nk.net...[color=blue]
> There's a number of elements that I set attributes for:
>
> <table border="1" cellpadding="3" cellspacing="0">..
>
> <img align="middle">
>
> Are there CSS equivalents for any of these?
>
> Jeff[/color]
C'mon, Jeff. These kinds of posts are gonna get you killfiled. Get your
ass some books or something. It is one thing to ask a legitimate
brain-burner of a question, but when your post reflects that you've
obviously not bothered to do your own homework, people get pissed.
-Karl | | | | re: CSS equivalents for attributes
For some odd reason, there's been a slew of partially correct
responses in this thread, and more heat then I'd expect from such a
simple question. Being foolish, I now stick my head in the lion's mouth.
Jeff Thies wrote:
[color=blue]
> There's a number of elements that I set attributes for:
>
> <table border="1" cellpadding="3" cellspacing="0">[/color]
<table cellspacing="0">
<!-- cellspacing is still required for IE 5.x Mac, which does not
recognize CSS border-spacing or border-spacing property -->
table {
border-collapse: collapse;
/* this will cause adjacent borders in table
to 'collapse' into one border */
}
td {
border: 1px solid black; /* borders around each cell */
padding: 3px; /* padding within each cell */
}
[color=blue]
> <img align="middle">[/color]
table img { /* assuming this image is inside the table */
vertical-align: middle;
}
And now, I wait to be shown how *I've* screwed up. Here's a preemtive :-P.
--
Brian (remove ".invalid" to email me) http://www.tsmchughs.com/ | | | | re: CSS equivalents for attributes
Karl Groves wrote:
[color=blue]
> "Jeff Thies" <jeff@spamalanadingong.com> wrote in message
> news:BEPIc.6982$kK.3273@newsread3.news.atl.earthli nk.net...
>[color=green]
>>There's a number of elements that I set attributes for:
>>
>><table border="1" cellpadding="3" cellspacing="0">..
>>
>><img align="middle">
>>
>>Are there CSS equivalents for any of these?
>>
>> Jeff[/color]
>
>
> C'mon, Jeff. These kinds of posts are gonna get you killfiled. Get your
> ass some books or something. It is one thing to ask a legitimate
> brain-burner of a question, but when your post reflects that you've
> obviously not bothered to do your own homework, people get pissed.[/color]
Well I've had my share of stupid posts. The earlier in the morning the
more likely. I'm more than a bit overextended.
It's not a trivial question although it seems that way. There's nothing
in CSS1 about tables. CSS2 support is more limited.
And as it turns out cellspacing is not obvious as it requires
border-collapse and border-spacing. Two properties that are not reliably
supported. That makes table borders in CSS a bit shaky.
Also, there appears to be no equivalent to <img align="middle"> The
obvious vertical-align: middle is a table cell thing.
Look at how far afield SpaceGirl had gotten by thinking these were
trivial (no offense meant).
Having said all that, I'll bear your advisory in mind.
Jeff
[color=blue]
>
> -Karl
>
>[/color] | | | | re: CSS equivalents for attributes
Jeff Thies wrote:
[color=blue]
> Also, there appears to be no equivalent to <img align="middle"> The[/color]
Given that "middle" isn't an allowed value for the align attribute, I'll
assume you mean "valign".
[color=blue]
> obvious vertical-align: middle is a table cell thing.[/color]
'vertical-align'
Value: baseline | sub | super | top | text-top | middle | bottom |
text-bottom | <percentage> | <length> | inherit
Initial: baseline
Applies to: inline-level and 'table-cell' elements
Not just a table cell thing.
--
David Dorward <http://blog.dorward.me.uk/> <http://dorward.me.uk/>
Home is where the ~/.bashrc is | | | | re: CSS equivalents for attributes
Brian <usenet3@julietremblay.com.invalid>
(news:10f7vldhqhtnqd0@corp.supernews.com) wrote:[color=blue]
> For some odd reason, there's been a slew of partially
> correct
> responses in this thread, and more heat then I'd expect
> from such a simple question. Being foolish, I now stick
> my head in the lion's mouth.
>
> Jeff Thies wrote:
>[color=green]
>> There's a number of elements that I set attributes for:
>>
>> <table border="1" cellpadding="3" cellspacing="0">[/color]
>
> <table cellspacing="0">
> <!-- cellspacing is still required for IE 5.x Mac, which
> does not recognize CSS border-spacing or border-spacing
> property -->
>
> table {
> border-collapse: collapse;
> /* this will cause adjacent borders in table
> to 'collapse' into one border */
> }
>
> td {
> border: 1px solid black; /* borders around each cell */
> padding: 3px; /* padding within each cell */
> }
>[color=green]
>> <img align="middle">[/color]
>
> table img { /* assuming this image is inside the table */
> vertical-align: middle;
> }
>
> And now, I wait to be shown how *I've* screwed up.[/color]
Right above :)
vertical-align should be set for the containing element (i.e. td), not the
contained (i.e. img).
Also, with border-collapse:collapse, cellspacing=0 is unnecessary
[color=blue]
> Here's
> a preemtive :-P.[/color]
What's that do after P? Drooling? :) | | | | re: CSS equivalents for attributes
>[color=blue]
> The "px" in "0px" might be unnecessary but for 2 reasons I would
> recommend to add it even in such case:
>[/color]
Yeah! why have these silly 'time saving' rules which are bound to cause
errors? also like you don't have to have a semicolon on the end of the last
declaration in a block, 'cos that wastes *so much* time!
RU | | | | re: CSS equivalents for attributes
> Support is good. And once you've used it once it won't seem[color=blue]
> complicated.
>
> <table cellspacing="5" cellpadding="3" border="1">
> to
> <table class="styled">
>
> table.styled {
> border-spacing: 5px;
> border-collapse: separate;
> border: thin black solid;
> }
> table.styled td {
> padding: 3px;
> }[/color]
Hi Chris,
border-spacing and border collapse are CSS2 aren't they - can you really say
support is good? (Nav6 and Op5)
RU | | | | re: CSS equivalents for attributes
On Tue, 13 Jul 2004 23:42:24 +0200, Mitja <nun@example.com> declared in
alt.html,comp.infosystems. www.authoring.stylesheets:[color=blue]
> Brian <usenet3@julietremblay.com.invalid>
> (news:10f7vldhqhtnqd0@corp.supernews.com) wrote:[color=green]
>> Here's
>> a preemtive :-P.[/color]
>
> What's that do after P? Drooling? :)[/color]
Nah, he missed a bit when shaving.
--
Mark Parnell http://www.clarkecomputers.com.au
"Never drink rum&coke whilst reading usenet" - rf 2004 | | | | re: CSS equivalents for attributes
Mitja wrote:
[color=blue]
> Brian wrote:
>[color=green]
>> Jeff Thies wrote:
>>[color=darkred]
>>> <table border="1" cellpadding="3" cellspacing="0">[/color]
>>
>> <table cellspacing="0">
>> <!-- cellspacing is still required for IE 5.x Mac, which
>> does not recognize CSS border-spacing or border-spacing
>> property -->
>>
>> table {
>> border-collapse: collapse;
>> /* this will cause adjacent borders in table
>> to 'collapse' into one border */
>> }
>>
>> td {
>> border: 1px solid black; /* borders around each cell */
>> padding: 3px; /* padding within each cell */
>> }
>>
>>[color=darkred]
>>> <img align="middle">[/color]
>>
>> table img { /* assuming this image is inside the table */
>> vertical-align: middle;
>> }
>>
>> And now, I wait to be shown how *I've* screwed up.[/color]
>
> Right above :) vertical-align should be set for the containing
> element (i.e. td), not the contained (i.e. img).[/color]
As I said, I was waiting to be shown up. I could note that vertical
align is applicable to inline elments, but that would be a dodge,
since the op was talking about a translation of table layout.
[color=blue]
> Also, with border-collapse:collapse, cellspacing=0 is unnecessary[/color]
Hold on there, cowboy. Cellspacing=0 most certainly is necessary, for
the reasons already given. (Look at the comments I put in my code
example.)
[color=blue][color=green]
>> Here's a preemtive :-P.[/color]
>
> What's that do after P? Drooling? :)[/color]
I was looking at someone eating ice cream. (Mmmm, ice cream....)
--
Brian (remove ".invalid" to email me) http://www.tsmchughs.com/ | | | | re: CSS equivalents for attributes
"Rupe" <rupert.alexander@virgin.net> writes:[color=blue][color=green]
> > Support is good. And once you've used it once it won't seem
> > complicated.
> >
> > <table cellspacing="5" cellpadding="3" border="1">
> > to
> > <table class="styled">
> >
> > table.styled {
> > border-spacing: 5px;
> > border-collapse: separate;
> > border: thin black solid;
> > }
> > table.styled td {
> > padding: 3px;
> > }[/color]
>
> Hi Chris,
>
> border-spacing and border collapse are CSS2 aren't they - can you really say
> support is good? (Nav6 and Op5)[/color]
Opera 5+ supports both properties.
IE5.0+ supports border-collapse but not border-spacing, so wide
cellspacing isn't possible. But generally people want to remove
cellspacing. [1]
NS6 supports border-spacing but not border-collapse (which it treats
as separate), so it gets a little odd with border-spacing: 0. But then
it's based on a pre-release Mozilla so bugs are to be
expected.
NS7/Mozilla 1.0+ support both properties.
Konqueror (3.2) has the same bug as NS6, but it's fixed in their CVS
so 3.3 will work fine - Safari, the other khtml browser, apparently is
fine with it, but I don't have one to test on.
The main problem is incorrect border-collapse support in NS6 and
Konqueror, and that's a minor cosmetic problem in two low-usage
browsers (and by the time Konqueror becomes high-usage, if it does,
this will be working).
[1] It's obviously bad for layout tables, but most data tables look
better with spacing '0' too.
--
Chris | | | | re: CSS equivalents for attributes
> > Hi Chris,[color=blue][color=green]
> >
> > border-spacing and border collapse are CSS2 aren't they - can you really[/color][/color]
say[color=blue][color=green]
> > support is good? (Nav6 and Op5)[/color][/color]
Chris wrote-------------------------------------
[color=blue]
>
> Opera 5+ supports both properties.
>
> IE5.0+ supports border-collapse but not border-spacing, so wide
> cellspacing isn't possible. But generally people want to remove
> cellspacing. [1]
>
> NS6 supports border-spacing but not border-collapse (which it treats
> as separate), so it gets a little odd with border-spacing: 0. But then
> it's based on a pre-release Mozilla so bugs are to be
> expected.
>
> NS7/Mozilla 1.0+ support both properties.
>
> Konqueror (3.2) has the same bug as NS6, but it's fixed in their CVS
> so 3.3 will work fine - Safari, the other khtml browser, apparently is
> fine with it, but I don't have one to test on.
>
>
> The main problem is incorrect border-collapse support in NS6 and
> Konqueror, and that's a minor cosmetic problem in two low-usage
> browsers (and by the time Konqueror becomes high-usage, if it does,
> this will be working).
>
> [1] It's obviously bad for layout tables, but most data tables look
> better with spacing '0' too.
>
> --
> Chris[/color]
Hmm interesting, thanks Chris.
Can I lead you astray for a moment? Is that allowed?
I have a problem with printing running headers/footers on a 'printer
friendly' page with CSS (I don't mean the ones the browser tacks on).
I came across this solution (below), but it seems pretty universally
unsupported. I assumed this is because its a CSS2 solution and, I assumed,
CSS2 ain't supported yet in virtually all browsers.
But now I see from your erudite reply that even IE 5.0 has CSS2 features...?
So how do I find out which browsers will print accordingly the following,
extremely handy, piece of code?
Running header:
<style>
@page {
@top{font-family: Helvetica, Arial, sans-serif;
font-size: 150%;
font-weight: bolder;
text-align: left;
content: "XHTML-Print: A Proposal --- August 25, 2000";
}
}
</style>
Running footer:
<style>
@page {
counter-increment: pages;
@bottom{font-family: Times, Palatino, serif;
font-size: 80%;
font-weight: normal;
text-align: center;
content: "Page " counter(pages);
}
}
</style>
[ http://www.pwg.org/xhtml-print/HTML-...html#page_area ]
Or maybe there is a more universal approach to solving the problem...?
My apologies if I posted 'out of line'.
RU | | | | re: CSS equivalents for attributes
"Rupe" <remove.spamwilleatitself.tosend.rupert.alexander@ virgin.net> writes:[color=blue]
> Can I lead you astray for a moment? Is that allowed?[/color]
It'd be better to start a new thread for it, or at least change the
subject line. That way other people who aren't watching the current
thread but do know the answer might help.
[color=blue]
> I came across this solution (below), but it seems pretty universally
> unsupported. I assumed this is because its a CSS2 solution and, I assumed,
> CSS2 ain't supported yet in virtually all browsers.[/color]
Isn't *completely* supported. Print styles less so than screen ones.
[color=blue]
> But now I see from your erudite reply that even IE 5.0 has CSS2 features...?[/color]
Even NS4 has the occasional CSS2 feature, it just implements them badly.
[color=blue]
> So how do I find out which browsers will print accordingly the following,
> extremely handy, piece of code?[/color]
Um, make a page with that code in, download the browser, try to print
the page with it. http://browsers.evolt.org/ for most browsers http://www.insert-title.com/web_desi...i_IE#downloads
for older IE versions.
[color=blue]
> Running header:
>
> <style>[/color]
Should be <style type='text/css'>
[color=blue]
> <style>[/color]
Likewise
--
Chris | | | | re: CSS equivalents for attributes
[color=blue]
>
> Um, make a page with that code in, download the browser, try to print
> the page with it.
> http://browsers.evolt.org/ for most browsers
>[/color] http://www.insert-title.com/web_desi...i_IE#downloads[color=blue]
> for older IE versions.
>[/color]
Thanks again Chris.
I thought you might say that! thats a heck alot of downloading. I shall
start with NS6 and work backwards.
[color=blue]
>Even NS4 has the occasional CSS2 feature, it just implements them badly.[/color]
'Dead Men Don't Wear Plaid' - "Don't ever say Xcleaning ladyX NS4!"
Regards
RU | | | | re: CSS equivalents for attributes
Chris Morris wrote:
[color=blue]
> IE5.0+ supports border-collapse but not border-spacing[/color]
IE 5+/*Win*, you mean. As I've written (twice in this thread!), IE
5.x/Mac does not support either. Thus, if the space is important to
you, you must set the table attribute cellspacing to 0.
--
Brian (remove ".invalid" to email me) http://www.tsmchughs.com/ | | | | re: CSS equivalents for attributes
Brian <usenet3@julietremblay.com.invalid> writes:[color=blue]
> Chris Morris wrote:[color=green]
> > IE5.0+ supports border-collapse but not border-spacing[/color]
>
> IE 5+/*Win*, you mean. As I've written (twice in this thread!), IE
> 5.x/Mac does not support either. Thus, if the space is important to
> you, you must set the table attribute cellspacing to 0.[/color]
Oops. Yes, I mean the windows version, usually I remember to make that
distinction.
--
Chris | | | | re: CSS equivalents for attributes
Chris Morris wrote:
[color=blue]
> Brian <usenet3@julietremblay.com.invalid> writes:
>[color=green]
>>Chris Morris wrote:
>>[color=darkred]
>>>IE5.0+ supports border-collapse but not border-spacing[/color]
>>
>>IE 5+/*Win*, you mean. As I've written (twice in this thread!), IE
>>5.x/Mac does not support either. Thus, if the space is important to
>>you, you must set the table attribute cellspacing to 0.[/color]
>
>
> Oops. Yes, I mean the windows version, usually I remember to make that
> distinction.
>[/color]
I'm inclined to think of support for IE5 Mac as being important.
Not so for NS6 or Knonquerer. Ay least for presentational issues.
It seems like a lot of webdesign is waiting for the bad browsers to go
away! Is NS4 still around?
I'd like to thank everyone for the help on what was to me, not simple!
Jeff | | | | re: CSS equivalents for attributes
Brian <usenet3@julietremblay.com.invalid>
(news:10f9c0knfusclde@corp.supernews.com) wrote:[color=blue]
> Mitja wrote:
>[color=green]
>> Brian wrote:
>>[color=darkred]
>>> Jeff Thies wrote:
>>>
>>>> <table border="1" cellpadding="3" cellspacing="0">
>>>
>>> <table cellspacing="0">
>>> <!-- cellspacing is still required for IE 5.x Mac, which
>>> does not recognize CSS border-spacing or border-spacing
>>> property -->
>>>
>>> table {
>>> border-collapse: collapse;
>>> /* this will cause adjacent borders in table
>>> to 'collapse' into one border */
>>> }
>>>
>>> td {
>>> border: 1px solid black; /* borders around each cell
>>> */ padding: 3px; /* padding within each cell */
>>> }
>>>
>>>
>>>> <img align="middle">
>>>
>>> table img { /* assuming this image is inside the table
>>> */ vertical-align: middle;
>>> }
>>>
>>> And now, I wait to be shown how *I've* screwed up.[/color]
>>
>> Right above :) vertical-align should be set for the
>> containing element (i.e. td), not the contained (i.e.
>> img).[/color]
>
> As I said, I was waiting to be shown up. I could note
> that vertical align is applicable to inline elments, but
> that would be a dodge, since the op was talking about a
> translation of table layout.
>[color=green]
>> Also, with border-collapse:collapse, cellspacing=0 is
>> unnecessary[/color]
>
> Hold on there, cowboy. Cellspacing=0 most certainly is
> necessary, for the reasons already given. (Look at the
> comments I put in my code example.)[/color]
I think there's a typo in those comments. You clearly meant border-collapse
and yes, I did overlook it (BTW, NN4.x doesn't recognize it either) - mea
culpa.
[color=blue]
>[color=green][color=darkred]
>>> Here's a preemtive :-P.[/color]
>>
>> What's that do after P? Drooling? :)[/color]
>
> I was looking at someone eating ice cream. (Mmmm, ice
> cream....)[/color] | | | | re: CSS equivalents for attributes
Mitja wrote:[color=blue]
> Brian wrote:
>[color=green]
>> Mitja wrote:
>>[color=darkred]
>>> Brian wrote:
>>>
>>>> cellspacing is still required for IE 5.x Mac, which does not
>>>> recognize CSS border-spacing or border-spacing property[/color][/color]
>
> I think there's a typo in those comments. You clearly meant
> border-collapse and yes, I did overlook it[/color]
I didn't notice my typo. It should have read "...does not recognize
border-spacing or border-collapse property".
As I feared, I think I may have confused matters more by trying to
correct the mistakes I saw.
[color=blue]
> (BTW, NN4.x doesn't recognize it either)[/color]
There's a lot NN4 doesn't recogize. And a lot it *does* recognize but
botches badly. At this point, I assume www authors do the simple and
sensible thing of hiding all CSS from that browser so that its users
can access the page without any real trouble.
--
Brian (remove ".invalid" to email me) http://www.tsmchughs.com/ | | | | re: CSS equivalents for attributes
Brian <usenet3@julietremblay.com.invalid>
(news:10faulholftls1c@corp.supernews.com) wrote:[color=blue]
> Mitja wrote:[color=green]
>> Brian wrote:
>>[color=darkred]
>>> Mitja wrote:
>>>
>>>> Brian wrote:
>>>>
>>>>> cellspacing is still required for IE 5.x Mac, which
>>>>> does not recognize CSS border-spacing or
>>>>> border-spacing property[/color]
>>
>> I think there's a typo in those comments. You clearly
>> meant border-collapse and yes, I did overlook it[/color]
>
> I didn't notice my typo. It should have read "...does not
> recognize border-spacing or border-collapse property".
>
> As I feared, I think I may have confused matters more by
> trying to correct the mistakes I saw.
>[color=green]
>> (BTW, NN4.x doesn't recognize it either)[/color]
>
> There's a lot NN4 doesn't recogize. And a lot it *does*
> recognize but botches badly.[/color]
Oh yessss:)
Just today I had to patch up a site to look a bit less revolting in NN4. The
little joys of life...
[color=blue]
> At this point, I assume www
> authors do the simple and sensible thing of hiding all
> CSS from that browser so that its users can access the
> page without any real trouble.[/color]
Hiding all css might be going a bit far. At least some borders, backgrounds
and such are welcome to show the structure of the page more clearly. | | | | re: CSS equivalents for attributes
Mitja wrote:[color=blue]
> Brian wrote:
>[color=green]
>> Mitja wrote:
>>[color=darkred]
>>> Brian wrote:[/color]
>>
>> There's a lot NN4 doesn't recogize. And a lot it *does* recognize
>> but botches badly.
>>
>> At this point, I assume www authors do the simple and sensible
>> thing of hiding all CSS from that browser so that its users can
>> access the page without any real trouble.[/color]
>
> Hiding all css might be going a bit far.[/color]
I must disagree. Its reported use is 5% or lower, and dropping.
[color=blue]
> At least some borders, backgrounds and such are welcome to show the
> structure of the page more clearly.[/color]
Sure. But it takes too much effort to figure out what *won't* make the
page explode in Netcape 4.x. I used to do it. Debugging, one CSS
property at a time, is quite labor-intensive, with not much payback.
--
Brian (remove ".invalid" to email me) http://www.tsmchughs.com/ |  | | | | /bytes/about
We are a network of experts and professionals in IT and software development that help one another with answers to tough questions and share insights.
Get the best answers to your questions from over 226,449 network members.
|