473,507 Members | 2,377 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Format a list into multiple columns, or dynamically display columnsusing CSS?

I'm sure this question has been asked before, but I couldn't seem to get
the right combination of words to get a hit.

I'm looking to do one of two things...

1) Take a list of items, and have them display in a table format, but
without any predetermined number of columns. Meaning that somehow using
CSS tell the browser to determine the amount of screen space available,
and then adjust the list items into an appropriate number of columns,
all lined up nice and pretty.

2) Similar to #1, take a list of items, and display them in a
predetermined number of columns.

If this is a FAQ, or documented in the CSS spec, please just point me to
the proper links and I'll take care of the rest of the reading myself.

Thanks,
Steve
Jul 20 '05 #1
1 4128
Steve <ng*****@digitalnothing.com> wrote:
I'm sure this question has been asked before, but I couldn't seem to
get the right combination of words to get a hit.
Try "multiple columns" (with quotation marks), in c.i.w.a.stylesheets
(since this is about appearance, is it not?).
1) Take a list of items, and have them display in a table format, but
without any predetermined number of columns.


The usual approach is basically
li { float: left; }
together with setting some reasonable width for the li elements (e.g.,
width: 8em if the longest item is less than about 20 characters).
But the topic really belongs to c.i.w.a.stylesheets.

(In HTML, the closest you can get, I presume, is to write the list items
just consecutively, just with spaces between them, with no list markup,
and pad them to the same number of characters using no-break spaces as
needed, and using e.g. <tt> markup to make the font monospaced. For some
more notes, and examples, see
http://www.cs.tut.fi/~jkorpela/HTML3...tml#menus-nbsp
This is of course a fairly clumsy method.)

--
Yucca, http://www.cs.tut.fi/~jkorpela/
Pages about Web authoring: http://www.cs.tut.fi/~jkorpela/www.html

Jul 20 '05 #2

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

Similar topics

1
2301
by: J.B | last post by:
I have a datagrid that will display different datasets, (it runs different sprocs based on a value in the querystring) but it will always return 6 columns. The 5th and 6th columns are always Date...
3
1837
by: david | last post by:
I have posted my question before. It seems that I can not find the solution. The question: I have datasource, say, ds which is bounded to a datagrid, dg. Assume that ds have 5 columns,...
0
1477
by: KBuser | last post by:
I'm building an internal site which will allow for extremely customizable queries to be run against our SQL Server (2000) DB. The page is done in ASP .net 2.0, with C# code behind. The initial...
4
7715
by: papa smerf | last post by:
I have a list box that I want to have 3 columns of data. For example: FirstName, LastName, Phone, Catagory I want to display the FirstName, LastName and Phone in the 3 columns, I will use...
3
6614
by: Harry Haller | last post by:
Hello, I want to implement a generic list which will be used to display 7 columns in a GridView. One should be able to sort, filter and page each of the 7 columns. Ideally the filter should be...
7
15612
by: =?Utf-8?B?TG9zdEluTUQ=?= | last post by:
Hi All :) I'm converting VB6 using True DBGrid Pro 8.0 to VB2005 using DataGridView. True DBGrid has a MultipleLines property that controls whether individual records span multiple lines. Is...
0
1366
by: madhanmss | last post by:
Hi, How to freeze multiple rows and columns in a datagrid. It should be like an excel sheet, if you scroll horizontally, columns should be freezed and if u scroll vertically, rows should be...
1
4611
gcoaster
by: gcoaster | last post by:
Hello Group, I was wondering if anyone out there can help me I have a form Unbound List Box Control on the form The row source is a built-in query. I was wondering if there is anyway to...
1
1786
by: Jonathan Wood | last post by:
I have a GridView control that displays the data in a List<object; My GridView contains the following in its definition: <asp:GridView ID="GridView1" runat="server" AutoGenerateColumns="False"...
0
7111
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...
0
7319
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,...
0
7376
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...
0
7485
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...
0
5623
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
4702
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...
0
1542
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
1
760
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
412
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...

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.