It was a recent discussion in this forum about whether it's good or bad to mix percentage and pixel values in table elements dimentions. I was rather surprised by posts about it, and think that I should clarify the case.
I state that it's not bad at all.
It is widely spread technique that can be useful for different tasks. For example, if you want to create a feel that the page layout covers entire window, while it actually consists of some fixed-width colomns with content and additional colomn with 100% width with some background.
----------------------
| 200px | 100% |
----------------------
This is just one example, but not the only one existing.
There are no any browser compatibility problems here. It never cause any problems in IE, Opera, old Netscape 4.x or new Mozilla. I personally used this method for years.
Of course - I tell this again - this should be done correctly. Use your knowledge and common sence. As you always should do.
As a proof of my words, here's an example: (don't go to the home page - they have some huge image there)
I usually never point to "live" projects I was involved in. This is an exception to the rule, because it illustrates the case and I think it can be helpful for you.
(Please note that the project was lauched about a year ago and I'm no longer involved in it. All the bugs you may found in page display in Mozilla or some weird formatting code, including huge ugly Dreamweaver preloader script - all this was done by those who support the project now.)
I don't say that what I show there is the only right way. It's just one of the possible implementations of this technique.
All I want to say is this: there are no methods defined as "good" or "bad" absolutely. Each method (if used properly) that helps you to achieve the goal is good - if it doesn't break the accepted rules, of course.
The method of using % and pixels in the same table does not break any HTML rule. Every professional will laugh in your face if you tell this. Don't think that it's not a valid way just because you never thought about it or didn't try to understand it.
Hope this is helpful.
Good luck to you.
I state that it's not bad at all.
It is widely spread technique that can be useful for different tasks. For example, if you want to create a feel that the page layout covers entire window, while it actually consists of some fixed-width colomns with content and additional colomn with 100% width with some background.
----------------------
| 200px | 100% |
----------------------
This is just one example, but not the only one existing.
There are no any browser compatibility problems here. It never cause any problems in IE, Opera, old Netscape 4.x or new Mozilla. I personally used this method for years.
Of course - I tell this again - this should be done correctly. Use your knowledge and common sence. As you always should do.
As a proof of my words, here's an example: (don't go to the home page - they have some huge image there)
I usually never point to "live" projects I was involved in. This is an exception to the rule, because it illustrates the case and I think it can be helpful for you.
(Please note that the project was lauched about a year ago and I'm no longer involved in it. All the bugs you may found in page display in Mozilla or some weird formatting code, including huge ugly Dreamweaver preloader script - all this was done by those who support the project now.)
I don't say that what I show there is the only right way. It's just one of the possible implementations of this technique.
All I want to say is this: there are no methods defined as "good" or "bad" absolutely. Each method (if used properly) that helps you to achieve the goal is good - if it doesn't break the accepted rules, of course.
The method of using % and pixels in the same table does not break any HTML rule. Every professional will laugh in your face if you tell this. Don't think that it's not a valid way just because you never thought about it or didn't try to understand it.
Hope this is helpful.
Good luck to you.