inChaos
-
Posts
4 -
Joined
-
Last visited
Content Type
Profiles
Forums
Events
Posts posted by inChaos
-
-
Tables
in HTML/XHTML
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html><head><title>table-exp</title><style type="text/css"><!--body{margin:0px;}table{width:770px;height:100%;}.menu{width:200px;background:pink;height:100%;}.content{background:blue;height:100%;}.footer{background:red;height:20px;}--></style></head><body><table cellpadding="0" cellspacing="0" border="0"><tr><td class="menu">menu</td> <td class="content">content</td></tr><tr><td colspan="2" class="footer">footer</td></tr></table></body></html>
************************next one is simular, but with div-s:************************
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html><head><title>div-exp</title><style type="text/css"><!--body{margin:0px;}.menu{width:200px;float:left;background:pink;height:100%;}.content{width:570px;float:left;background:blue;height:100%;}.footer{width:770px;clear:left;background:red;height:20px;}--></style></head><body><div class="menu">menu</div><div class="content">content</div><div class="footer">footer</div></body></html>
try this examples - it fits all the body ONLY if you remove the doctype tag, or if the doctype tag is for html...
-
Tables
in HTML/XHTML
in the XHTML doctype i tried all to make element - <p>, or <div>, or table, or table cell with 100% heightit works, at the moment i change the doctype to html 4.01 for example....is it possible they simply do not have 100% height of the element in the xhtml?Maybe it is that you thought the table wouldn't expand, but it did and that the cell was the one that didn't. You should add the 100% to the cell too, so it would fill its parent table -
this works if you have:<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">(or the default doctype...) but this is HTNLbut if doctype is:<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">wich is XHTML...then there is no 100% of height...the same for tables or any tag - az i see...Is XHTML can support height:100% at all?as much as i can see - no... anyone?hi again mani_!i tried searching for body margin but all i can find are the margins for paragraph. ill try searching some more but if you happen to have the code i'd really appreciate it thanks again so much!Jonas gave me this html code and i want it to appear like this but the code you gave me will make it so much easier because of the div left and right. hope you can help me again <html><head><title>Untitled</title><style type="text/css"><!--body {background-color: pink;}div#left {width: 50%; /* will make the div half the total width of your page. */height: 100%;position: absolute;top: 0px;left: 0px; /* sticks your div in the top-left corner of your page. */background-color: black;}--></style></head><body><div id="left"><font color="#2B60DE"> Menu content, or whatever you want...</div></body></html>
Tables
in HTML/XHTML
Posted
sorry guys, i added height 100% to body and it works....perhaps should read more carreffully...and learn to write en english, of course:)see ya:)