Forum Moderators: coopster & phranque

Message Too Old, No Replies

Dynamic table generation and sorting

         

Marcia

10:45 am on May 31, 2002 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



In laboring through a long unsorted product list that needs to be put into a table on a web page in alphabetical order, an order form to print and mail or fax, I recall having read a while back that there's a way to dynamically generate HTML tables and also, to sort them.

The closest I can recall it's got something to do with data binding; the data is sorted by clicking on the table header. The table itself is generated with <object> tags used.

Any clues on where to start, and how this is done?

sparrow

12:11 pm on May 31, 2002 (gmt 0)

10+ Year Member



marcia, I picked up a book by Larry Ullman about advanced PHP, I am currently reading about this exact situation.

>>looking.....

now that I want the commands I cant find them, when I do, I'll post it.

sparrow

12:29 pm on May 31, 2002 (gmt 0)

10+ Year Member



Is the product list in a text file?

PHP sort function example;

ksort($results);

Nick_W

12:53 pm on May 31, 2002 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Yep, tell us how the data is stored Marcia. There are a few options I can think of all involving ksort() as mentioned but the way to do it will depend on how the data is stored.

Nick

Marcia

4:50 pm on May 31, 2002 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



>tell us how the data is stored

The data is stored in an email message. :)

Nick_W

5:01 pm on May 31, 2002 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Uhggg!

You'll have to do something about it.

Is it a msg that will be regularly sent by someone to you?

If so, ask them to make a text file with 1 item per line and attach it.

Tell more, marcia, It's tough to work on guess work alone ;)

Nick

sun818

8:36 am on Jun 5, 2002 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



Hi Marcia -- Try the first result in a Google search using these keywords:

table sort "data binding"

You will have to get the e-mail into a comma separated file or tab delimited file to do what you want.