/* creating object, attribute, add row, td, txt functions */
load.push('make("DIV")');
attr=function(el,attr,val)
{	if(!val) return (!ns6)?el.getAttribute(attr):(el.hasAttribute(attr))?el.getAttribute(attr):null;
	else el.setAttribute(attr,val,false);
}
/* node generating */
add=function(tag,cls,par)
{	var ob=document.createElement(tag);
		ob.className=(cls)? cls:''; 
	if(par) par.appendChild(ob)
return ob;
}
txt=function(txt,par)
{	var tob=document.createTextNode(txt);
	par.appendChild(tob);
return tob;
}
/* table dynlite module */
/* @version: 2.2.0.1/2004-12-13 */

dyntbl=function(id,head,par)
{	this.id=this.cls=id;
	this.par=(par)? par:document.body
	this.tbl=add('TABLE',this.cls,this.par);
	this.addHead(head);
}
dyntbl.prototype.addHead=function(text)
{	this.root=this.tbl.createTHead();
	this.head=this.addRow();
	this.cell=add('TH',this.cls,this.head);
	this.cell.className=this.cls;
	txt(text,this.cell)
	this.root=this.tbl;
}
dyntbl.prototype.addRow=function()
{	this.row=this.root.insertRow(this.root.rows.length);
	this.row.className=this.cls;
return this.row;	
}
dyntbl.prototype.addCell=function(text,cls)
{	this.cell=this.row.insertCell(this.row.cells.length);
	cls=(cls)? ' '+cls:''; 
	this.cell.className=this.cls+cls;
	txt(text,this.cell)
	if(this.head.cells.length<this.row.cells.length)	
		attr(this.head.firstChild,'colspan',this.row.cells.length);
return this.cell;	
}
/* end of table module */