![]() |
|
|
|||||||
![]() |
HTML - making a table grow horizontally rather than vertically, possiblyusing frames |
|
|
Thread Tools | Search this Thread |
|
|
#1 |
|
I have a frame-based application that shows two table rows in the
bottom-most frame of the window. The problem I'm having is that if I try to show too much data down there, the table always grows row size vertically by using excessive amounts of wrapping. If I try to show this page on a small screen, like a laptop, the excessive amount of wrapping produces output that is unreadable (table cells that are ten lines tall with one word per line). What I'd much rather have happen is for the table to grow the rows horizontally, adding a horizontal scrollbar as necessary. I've tried a couple of approaches to this, the first being to try to apply the "max-height" property to <TD> or <TR> via css, but this attribute seems to be either outright ignored or unsupported. I also tried the following, which seems like it should work, but does nothing: <style> td { white-space:nowrap; } </style> Even if I could get nowrap to work, that's suboptimal as I'd really like to allow one line of wrapping (each table cell a maximum of two lines high). Any ideas? Scott Scott |
|
|
|
|
#2 |
|
Posts: n/a
|
On Oct 28, 11:56*pm, Scott <smba...@gmail.com> wrote:
> Any ideas? > > Scott use percent? Jan C. Faerber |
|
|
|
#3 |
|
Posts: n/a
|
On Wed, 28 Oct 2009 15:56:00 -0700 (PDT), Scott wrote:
> I have a frame-based application that shows two table rows in the > bottom-most frame of the window. The problem I'm having is that if I > try to show too much data down there, the table always grows row size > vertically by using excessive amounts of wrapping. If I try to show > this page on a small screen, like a laptop, the excessive amount of > wrapping produces output that is unreadable (table cells that are ten > lines tall with one word per line). > > What I'd much rather have happen is for the table to grow the rows > horizontally, adding a horizontal scrollbar as necessary. > > I've tried a couple of approaches to this, the first being to try to > apply the "max-height" property to <TD> or <TR> via css, but this > attribute seems to be either outright ignored or unsupported. I also > tried the following, which seems like it should work, but does > nothing: > > <style> > td { > white-space:nowrap; > } > </style> > > Even if I could get nowrap to work, that's suboptimal as I'd really > like to allow one line of wrapping (each table cell a maximum of two > lines high). > > Any ideas? > > Scott height:100px; width:auto; replace 100px with what ever value you need. richard |
|
|
|
#4 |
|
Posts: n/a
|
In article
<7f5facb4-13c0-4c57-a3f6->, Scott <> wrote: > I have a frame-based application that shows two table rows in the > bottom-most frame of the window. The problem I'm having is that if I > try to show too much data down there, the table always grows row size > vertically by using excessive amounts of wrapping. If I try to show > this page on a small screen, like a laptop, the excessive amount of > wrapping produces output that is unreadable (table cells that are ten > lines tall with one word per line). > > What I'd much rather have happen is for the table to grow the rows > horizontally, adding a horizontal scrollbar as necessary. > > I've tried a couple of approaches to this, the first being to try to > apply the "max-height" property to <TD> or <TR> via css, but this > attribute seems to be either outright ignored or unsupported. I also > tried the following, which seems like it should work, but does > nothing: > > <style> > td { > white-space:nowrap; > } > </style> > > Even if I could get nowrap to work, that's suboptimal as I'd really > like to allow one line of wrapping (each table cell a maximum of two > lines high). > > Any ideas? > You can't control so exactly the number of lines in advance. But you can do other things to alleviate the problem. How about trying a few numbers to suit you like in: td {min-width: 20em;} Browser support might be an issue but take a look. -- dorayme dorayme |
|
|
|
#5 |
|
Posts: n/a
|
On 28 Oct 2009, Scott <> wrote:
> I have a frame-based application that shows two table rows in the > bottom-most frame of the window. The problem I'm having is that if I > try to show too much data down there, the table always grows row size > vertically by using excessive amounts of wrapping. If I try to show > this page on a small screen, like a laptop, the excessive amount of > wrapping produces output that is unreadable (table cells that are ten > lines tall with one word per line). > > What I'd much rather have happen is for the table to grow the rows > horizontally, adding a horizontal scrollbar as necessary. > > I've tried a couple of approaches to this, the first being to try to > apply the "max-height" property to <TD> or <TR> via css, but this > attribute seems to be either outright ignored or unsupported. I also > tried the following, which seems like it should work, but does > nothing: > > <style> > td { > white-space:nowrap; > } > </style> You're either using an archaic browser or you screwed up. white-space:nowrap; works fine on a td. > Even if I could get nowrap to work, that's suboptimal as I'd really > like to allow one line of wrapping (each table cell a maximum of two > lines high). How would the 1st line know to break and the 2nd not? That might be a wee bit difficult to impliment. -- Neredbojias http://www.neredbojias.org/ http://www.neredbojias.net/ Neredbojias |
|
|
|
#6 |
|
Posts: n/a
|
On Oct 29, 10:20*am, Neredbojias <neredboj...@gmail.com> wrote:
> > tried the following, which seems like it should work, but does > > nothing: > > > <style> > > td { > > white-space:nowrap; > > } > > </style> > > You're either using an archaic browser or you screwed up. > white-space:nowrap; works fine on a td. seems plausible Jukka's discussion and a second link: http://archivist.incutio.com/viewlist/css-discuss/51261 http://www.w3.org/MarkUp/html3/tables.html Jan C. Faerber |
|
![]() |
| Thread Tools | Search this Thread |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Burning CD's (Long - error log included) | fiddaman64 | Computer Support | 11 | 05-11-2005 01:49 PM |
| An interesting concept - Somebody's watching you | johnyreb | Computer Support | 1 | 03-06-2005 02:42 PM |