SiteExperts.com Logo Home | Community | Developer's Paradise
User Groups | Site Tools | Site Information | Search
 Main Menu
 Resource

Cross Browser Dynamic HTML Tables


Sponsored Links
Developer's Paradise : Inside Technique :
Cross Browser Dynamic HTML Tables
Submission by SiteExperts Staff

Go to the resource:
Cross Browser Dynamic HTML Tables

Add to Assistant

Short Description
Build Cross-Browser JavaScript Dynamic HTML tables that support filtering and sorting using.

Long Description
Assume you have to publish a set of some hundred records of tabular data the types of which are quite simple such as a logical yes/no data, a number, a short text or a calendar date. In most cases it's useful to present these data in form of a dynamic HTML table, i.e. a table that enables your audience to analyze the data through sorting and filtering the records and to display these records step by step instead of presenting them all at once.

This paper describes how you can easy build up such cross-browser dynamic HTML tables only by means of simple JavaScript.

Author
Dieter Bungers
Date/ Version
5/6/2000
Submission URL
http://www.SiteExperts.com/tips/databinding/ts06/paper/dhtml_table.htm
Submission Date
May 6,2000
Last Update
May 6,2000
 

Discussion and Rate this Resource
Overall Rating: 4.6

yhaber on Aug 3, 2003 at 12:58:02 AMRating: 5

it is very short and neet piece of code and also a very usfule one.

simham_uk on Jul 13, 2003 at 7:06:30 AMRating: 5

Excellent piece of code, but has anyone managed to get this to work inside an existing page, inside a div, or another table?

If so could you please help me before I cry like a baby, and email suggestions to me at the address below, or post here.

Thanks in advance!

Simon H - simon dot hamilton at ntlworld dot com

mrfritz on May 29, 2002 at 12:58:43 PMRating: 5

This is great stuff... my boss thinks I'm a genius! Sadly, I had to tell him a guy named
Dieter in Germany actually wrote this...

Anyway, I think I found a couple of problems with the handling of numeric columns:

1) When the number stored in the "theTab.js" is "0", nothing appears in the table. In our
case, we want the actual 0 to appear, not a blank. Is this fixable?

2) This one is trickier. When a blank is stored in the numeric column, and when this is the last column in the
table, the page doesn't display.

Here's an example from our "theTab.js" file:


var theCols = new Array();
theCols[0] = new Array("Code", 4, 6);
theCols[1] = new Array("Description", 4, 200);
theCols[2] = new Array("Precision", 1, 11);

var theRows = new Array(), ir=0;
theRows[ir++] = new Array ("WST", "Samoan Tala",2);
theRows[ir++] = new Array ("XAF", "CFA Franc BEAC",0);
theRows[ir++] = new Array ("XAG", "Silver",);  //<-- note the blank number here

I tried putting " " in place of the blank, like ths, ("XAG", "Silver",""); This got the page
to display, but the sorting and filtering didn't behave properly.

If you have any time, I would appreciate your help.

AlexEl on Mar 16, 2002 at 3:09:34 AMNo Rating

Наш INTERNET CLUB предлагает к вашим услугам:
работа в Internet, сетевые игры, набор и распечатка, изготовление визиток, буклетов, ксерокс, а также компьютерные курсы

cgisackson on Dec 18, 2001 at 6:04:16 AMRating: 5
Highly useful and informative code throughout this application.

More Ratings/ Comments


To rate and comment on a resource, you must first logon.

If you are not registered, please register yourself to become a member of the SiteExperts.community.

User Name
Password

Copyright © 1997-2008 InsideDHTML.com, LLC. All rights reserved.