Badtable


Add Rows

The add_rows() method is used to define a group of body rows in your table.

add_rows(array row)

Example:

$data = array(
	array('Fred', 'Blue', 'Small'),
	array('Mary', 'Red', 'Large'),
	array('John', 'Green', 'Medium')	
);

$this->badtable->add_rows($data);

add_rows (array row [,array attributes])

The key specified in the attributes array will relate to the row number the attributes are applied.

Example:

$data = array(
	array('Fred', 'Blue', 'Small'),
	array('Mary', 'Red', 'Large'),
	array('John', 'Green', 'Medium')	
);

$attr = array(
	0 => array('class' => 'highlight'),
	2 => array('class' => 'highlight')
);

$this->badtable->add_rows($data, attr);