mynamesleo Posted November 15, 2006 Share Posted November 15, 2006 Hi all, hopefully a silly question hereHow do you keep textwithin a table? [code]<table style='table-layout:fixed' valign='top' align='left' border='1' width='40'><tr><td>AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA HATE HTML AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA123</td></tr></table>[/code]That text goes all over and past the table and is a mess! Thanks in advance Link to comment https://forums.phpfreaks.com/topic/27366-easy-one-table-text/ Share on other sites More sharing options...
Telemachus Posted November 15, 2006 Share Posted November 15, 2006 That's the whole point of table-layout:fixed, it will stay 40 pixels wide no matter what's inside it. You'd need to reduce the length of text between spaces to what fits. Link to comment https://forums.phpfreaks.com/topic/27366-easy-one-table-text/#findComment-125236 Share on other sites More sharing options...
fenway Posted November 15, 2006 Share Posted November 15, 2006 Why "fixed"? Tables are always the "right" size -- that's why everyone uses them (unlike CSS). Link to comment https://forums.phpfreaks.com/topic/27366-easy-one-table-text/#findComment-125266 Share on other sites More sharing options...
mynamesleo Posted November 16, 2006 Author Share Posted November 16, 2006 Well if the table width changes it will mess up my whole layout, before I had a table (forget how) but whatever text was in it would automaticly stay inside the table and sort it self out, the height of the table would grow but width would stay the same Link to comment https://forums.phpfreaks.com/topic/27366-easy-one-table-text/#findComment-125465 Share on other sites More sharing options...
fenway Posted November 16, 2006 Share Posted November 16, 2006 So why not put it into a DIV with fixed width and overflow:hiddne? Link to comment https://forums.phpfreaks.com/topic/27366-easy-one-table-text/#findComment-125726 Share on other sites More sharing options...
mynamesleo Posted November 16, 2006 Author Share Posted November 16, 2006 [quote author=fenway link=topic=115100.msg469133#msg469133 date=1163707120]So why not put it into a DIV with fixed width and overflow:hiddne?[/quote]Thankyou Link to comment https://forums.phpfreaks.com/topic/27366-easy-one-table-text/#findComment-125765 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.