Skip to content

classes_lib_controls_table_tbody.class

Daniel Spors edited this page Feb 14, 2023 · 3 revisions

Classes in file lib/controls/table/tbody.class.php

class TBody

This is tbody in div annotation.

Namespace: ScavixWDF\Controls\Table

Extends: Control » Renderable

Subclasses: TFoot, THead

GetCell

SHORTCUT To get a cell from the current row (Tr::GetCell)

GetCellContentArray

Returns all cells contents as array. Note that this will return a two-dimensional array as it loops thru all rows and for each thru all it's cells.

Definition: public function GetCellContentArray()

Returns: array Contents of all cells

GetCurrentRow

Return the current row, if any.

Definition: public function GetCurrentRow()

Returns: Tr The last added row object or false

GetMaxCellCount

Returns the maximum cell count. Loops thru all rows and finds the maximum count of cells in a row.

Definition: public function GetMaxCellCount()

Returns: int Maximum cell count

Header

Creates a header. We treat tbody headers as the first row in the tbody element.

Definition: public function Header()

Returns: Tr The created header

NewCell

SHORTCUT To create a new cell in the current row (Tr::NewCell)

NewRow

Creates a new row.

Definition: public function NewRow($data=false, $options=false)

Returns: Tr

Parameters:

  • array $data If given creates new cells in the row (see Tr::NewCell)

  • array $options See Tr for options

Rows

Returns all rows.

Definition: public function Rows()

Returns: array List of Tr objects

SetAlignment

Sets the alignment for all rows.

Definition: public function SetAlignment($alignment)

Returns: static

Parameters:

  • array $alignment Array of alignments for each column l(eft)|r(ight)|c(enter)

WdfRender

OVERRIDE Control::WdfRender

__construct

Constructs a new TBody. Possible options:

  • 'collapsible' := true|false
  • 'visible' := true|false

Definition: public function __construct($options, $class, $parent_table=false)

Returns: NOT DOCUMENTED

Parameters:

  • array $options Options

  • string $class Classname

  • Table $parent_table The parent table this belongs to

Clone this wiki locally