473,651 Members | 2,659 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Table height in percents

Hi,

It seems like HTML 4.01 Transitional spec. doesn't allow table height
to be expressed in percents.

When i have this doctype tag:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
the percents don't work.

I need to make my HTML to be valid 4.01, how can i make a table
populate the whole page? In other words how can i get the same effect
as width="100%" and height="100%"

Thanks,
Alex
Jul 20 '05 #1
9 9974
In post <4c************ **************@ posting.google. com>
alex said...
It seems like HTML 4.01 Transitional spec. doesn't allow table height
to be expressed in percents.
height is not a valid attribute of <table> in any HTML specification
I need to make my HTML to be valid 4.01, how can i make a table
populate the whole page?
you shouldn't be using tables for layout. having valid html isn't much
use if your document is broken from the start.
In other words how can i get the same effect
as width="100%" and height="100%"


<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<title>blah</title>
<style type="text/css">
html,body{margi n:0;padding:0;h eight:100%;}
table{width:100 %;height:100%;b order:1px solid red;}
</style>
<table><tr><td> blah</td></tr></table>
--
brucie a. blackford. 02/August/2003 07:44:53 am kilo.
http://loser.brucies.com/
Jul 20 '05 #2
"brucie" <br******@loser .brucies.com> wrote in message
news:1w******** *******@alt-html.org...
In post <4c************ **************@ posting.google. com>
alex said...
I need to make my HTML to be valid 4.01, how can i make a table
populate the whole page?


you shouldn't be using tables for layout. having valid html isn't much
use if your document is broken from the start.


Out of curiosity (and a lack of finding good info on w3.org), what is the
preferred (standard) method of columnar layout? I never read much about the
table specifications until now, and I can't seem to find where it says using
tables for containing other parts of the layout tree is bad. (I'm sure I'm
not looking quite hard enough.) Do you have a link where I can just start
reading how to layout columns the "proper" way?

I use columns all the time for my layouts' navigation. Until I find out
different, I always use a single-row table to split the page into two or
three columns. I always thought it was kind of clunky, but it got the job
done, and I do feel that it's a bit of a violation of a "good" parse tree to
use a data layout method for page layout.

I looked up COL and COLGROUP, but they are only relative to a table in
context.

Thanks for anyone's advice,
Zac
Jul 20 '05 #3
In post <3f********@new s.enetis.net>
Zac Hester said...
you shouldn't be using tables for layout. having valid html isn't much
use if your document is broken from the start.
Out of curiosity (and a lack of finding good info on w3.org), what is the
preferred (standard) method of columnar layout?
CSS
I never read much about the table specifications until now, and I can't seem
to find where it says using tables for containing other parts of the layout
tree is bad.
<quote>
Tables should not be used purely as a means to layout document content
as this may present problems when rendering to non-visual media.
Additionally, when used with graphics, these tables may force users to
scroll horizontally to view a table designed on a system with a larger
display. To minimize these problems, authors should use style sheets
to control layout rather than tables.
</quote> http://www.w3.org/TR/html401/struct/tables.html#h-11.1

also: B.5 Notes on tables
http://www.w3.org/TR/html401/appendi...l#notes-tables
Do you have a link where I can just start reading how to layout columns the
"proper" way?


its very easy to achieve column layouts with CSS

1-3-1 100% available height layout
http://usenet.alt-html.org/1-3-1-css-layout.html

2-1-3-1 content of areas dictates height layout. widths are whatever
you feel like and can be mixed unlike tables:
http://usenet.alt-html.org/2-1-3-1-css-layout.html

but unfortunately IE doesn't support the easiest way to do it so a bit
of playing around or using a different method is needed to support
crappy IE. M$ should be shot.

CSS layout examples:
http://www.glish.com/css/
http://www.csszengarden.com/
http://www.wannabegirl.org/css/
http://tantek.com/CSS/Examples/
http://www.saila.com/usage/layouts/
http://www.bluerobot.com/web/layouts/
http://www.benmeadowcroft.com/webdev/
http://www.xs4all.nl/~apple77/columns/
http://www.meyerweb.com/eric/css/edge/
http://www.htmler.org/tutorials/3/1.html
http://css.nu/articles/floating-boxes.html
http://webhost.bridgew.edu/etribou/layouts/
http://www.roguelibrarian.com/lj/index.html
http://css-discuss.incutio.com/?page=CssLayouts
http://ecoculture.com/styleguide/r/rollovers.html
http://thenoodleincident.com/tutoria...son/index.html
http://www.webreference.com/authorin...yout/advanced/

--
brucie a. blackford. 02/August/2003 09:04:48 am kilo.
http://loser.brucies.com/
Jul 20 '05 #4
"brucie" <br******@loser .brucies.com> wrote in message
news:jb******** *******@alt-html.org...

<snip>A whole lot of useful info...</snip>

brucie a. blackford. 02/August/2003 09:04:48 am kilo.
http://loser.brucies.com/


Thanks a ton! This is exactly what I was looking for. It's too bad that we
have to tip-toe around this M$ crap all the time. I did like the
closing-bracket bug, though. I have a lot more uses for that little gem.

Thanks again,
Zac
Jul 20 '05 #5
<CITE from="http://www.w3.org/TR/html401/struct/tables.html#h-11.1">

The HTML table model has been designed so that, with author assistance, user
agents may render tables incrementally (i.e., as table rows arrive) rather
than having to wait for all the data before beginning to render.

</CITE>

Excellent! <TABLE style="height:1 00%"> How?

<CITE from="http://www.w3.org/TR/html401/struct/tables.html#h-11.1">

In order for a user agent to format a table in one pass, authors *MUST* tell
the user agent:

a.. The number of columns in the table. Please consult the section on
calculating the number of columns in a table for details on how to supply
this information.
b.. The widths of these columns. Please consult the section on calculating
the width of columns for details on how to supply this information.
</CITE>

Is this valid HTML by the standard?
<TABLE>
<TR><TD><TD></TR>
<TR><TD><TD><TD ><TD></TR>
....
<!--somewhere at the end-->
<TR><TD><TD><TD ><TD><TD><TD> </TR>
</TABLE>

If yes, could anybody explain me what the hell is this *must* mean?

What renderer should do with the rest?

Is there somewhere LOGICtidy application? Could you give it to authors?

And don't blame on browsers, please. They are trying to render this fuzzy
set.

Andrew.
http://terra-informatica.org

Jul 20 '05 #6
"Andrew Fedoniouk" <an****@terra-informatica.org > wrote:
<CITE from="http://www.w3.org/TR/html401/struct/tables.html#h-11.1">

The HTML table model has been designed so that, with author assistance, user
agents may render tables incrementally (i.e., as table rows arrive) rather
than having to wait for all the data before beginning to render.

</CITE>

Excellent! <TABLE style="height:1 00%"> How?
Sorry, what's your point? The HTML spec refers to just HTML if you add
CSS on top of that you may end up putting the browser in the position
of having to choose whether to follow the HTML or the CSS...
<CITE from="http://www.w3.org/TR/html401/struct/tables.html#h-11.1">

In order for a user agent to format a table in one pass, authors *MUST* tell
the user agent:

a.. The number of columns in the table. Please consult the section on
calculating the number of columns in a table for details on how to supply
this information.
b.. The widths of these columns. Please consult the section on calculating
the width of columns for details on how to supply this information.
</CITE>

Is this valid HTML by the standard? <TABLE>
<TR><TD><TD> </TR>
<TR><TD><TD><T D><TD></TR>
<TR><TD><TD><T D><TD><TD><TD> </TR>
</TABLE>
Yes it's valid. But it does not meet the additional criteria that you
quote above.
If yes, could anybody explain me what the hell is this *must* mean?


Look at the <col> element. That's what tells the browser the number of
columns. As you haven't included any <col>s then the browser can not
"format a table in one pass"

Steve

--
"My theories appal you, my heresies outrage you,
I never answer letters and you don't like my tie." - The Doctor

Steve Pugh <st***@pugh.net > <http://steve.pugh.net/>
Jul 20 '05 #7
> Look at the <col> element. That's what tells the browser the number of
columns. As you haven't included any <col>s then the browser can not
"format a table in one pass"


<TABLE>
<COL>
<TR><TD><TD></TR>
<TR><TD><TD><TD ><TD></TR>
<TR><TD><TD><TD ><TD><TD><TD> </TR>
</TABLE>

And now it can?

"In order for a user agent to format a table in one pass, authors *MUST*
tell
the user agent...."

I did. So what?
Andrew.
http://terra-informatica.org

Jul 20 '05 #8
"Andrew Fedoniouk" <an****@terra-informatica.org > wrote:
Look at the <col> element. That's what tells the browser the number of
columns. As you haven't included any <col>s then the browser can not
"format a table in one pass"


<TABLE>
<COL>
<TR><TD><TD> </TR>
<TR><TD><TD><T D><TD></TR>
<TR><TD><TD><T D><TD><TD><TD> </TR>
</TABLE>

And now it can?

"In order for a user agent to format a table in one pass, authors *MUST*
tell
the user agent...."

I did. So what?


So if a browser only displays the first table cell in each row you
only have yourself to blame.

More likely the browser will realise that you have made an error and
will reformat the table, i.e. it will take more than one pass. As you
haven't complied with the requirements given you can't expect anything
else.

Steve

--
"My theories appal you, my heresies outrage you,
I never answer letters and you don't like my tie." - The Doctor

Steve Pugh <st***@pugh.net > <http://steve.pugh.net/>
Jul 20 '05 #9
Andrew Fedoniouk wrote:
<quote>
Tables should not be used purely as a means to layout document content
as this may present problems when rendering to non-visual media.
To minimize these problems, authors should use style sheets
to control layout rather than tables.


<LI style="margin-left:-100px; position:absolu te:top:-10000px" >Lets full
the Lynx. It will think that I am list item. But I am not! Some wise
author (or might be user) applied some weird CSS style to my pure
body.</LI>


The <li> element type is to put items into lists. If you don't follow that
part of the specification, then what makes you think the advice given in
other parts of the specification will still hold true?

HTML and CSS are not designed to obviate the need for human intelligence
when marking up documents. Is it a list? No? The don't use any of the
list element types.
[snip] CSS it just an Eldorado for spammers. They can full any content analyzer.


CSS isn't content.
--
Jim Dabell

Jul 20 '05 #10

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

14
2141
by: Carl Gilbert | last post by:
Hi I am currently writing a site that utilises tables. I have one page that links to a second page. The only problem is that when I link to the second page, the table loads up with a different height than was set in the code. However, when I use the navigation buttons in IE to go back and then forward again to the second page, the table is displayed as expected.
3
4872
by: Bootstrap bill | last post by:
I have an iframe embedded in a single cell table. I'd like to resize the table and iframe to match any changes made to window size. Is this possible? -- "It's easy enough to be pleasant, when life hums along like a song. But the man worth while is the man who can smile when everything goes dead wrong.".
8
39512
by: brett | last post by:
How can I find the height and width of a webpage? Say I want to make sure someone's webpage is within an 800X600 viewing area. Width is the most important but if I can get width, I should also be able to get height. I don't need to modify the page in anyway. Just get the width and height. I can reference the page in an iframe, cfhttp (CFMX) or something if it needs to be on my server. Thanks,
2
16636
by: Georg Goerg | last post by:
hello, i want to make website with a top navigation bar and one on the left. so by using css i define three layers and everyone of them has length attr. in percents. but if i want to put (square) images in e.g. the top bar, which should fill out the whole height of the bar, it depends on the screen resolution, wether they look like square images or rectangles.
3
2031
by: Chifo | last post by:
hello. i have a problem with a populate html table with data from table here it's the problem two querys retrieving data from table, one of querys show me a colletion of data from 6:00 am to 15:30 pm timestampz, i put this on a part of html table. when time on my if condition es great than 15:31, showme data from 15:31 to 23:59 timestamp and populate another part of html table. but, data in html first part,it's gone away.
18
3326
by: zzpat | last post by:
I've come to the conclusion that float was never made for designing a page, but is there a good way to float three columns with the following characteristics? leftColumn 20% rightColumn 20% centerColumn use what's left I'm currently defining centerColumn as a %, but to get this to work properly the margin, padding and border settings have to be exactly the
1
5191
by: MissMarie | last post by:
I've been playing around with DIV tables in myspace to better learn how to rewrite my own code for my business site without having to pay someone to design it. I've tried embedding a slideshow into a div table and after I save it I noticed that the slideshow does not show up and the embed code I added is altered. Can anyone help me figure this out? The embed code that I'm talking about is three quarters down the code page under {PHOTOS},...
6
4801
by: Stephan Bourdon | last post by:
Hi, Your opinion please on the following subject: Is it acceptable to set the width and height of an image in ems or percents in CSS? The advantage for me is that images will scale up or down when the user changes the font size in the browser. But what of the disadvantages? In (X)HTML, the img-element will have a pixel-value for the width and height-attributes.
3
3143
by: jonceramic | last post by:
Hi All, I need to know the best way to set up a datawarehouse/materialized view for doing statistics/graphs in Access. My crosstabs and unions are getting too complicated to crunch in real time. Should I use a make-table I run after each update? Thanks,
0
8347
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8275
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
8792
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
8694
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
8457
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
8571
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
5605
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4280
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
1585
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.