XBSLOG
[ class tree: XBSLOG ] [ index: XBSLOG ] [ all elements ]

Class: logTableForm

Source Location: /class/class.log.form.php

Class Overview


A table with edit capabilities per row


Methods



Class Details

[line 29]
A table with edit capabilities per row



[ Top ]


Class Methods


constructor logTableForm [line 60]

logTableForm logTableForm( array $colNames, [string $title = null], [boolean $dispKey = true], [string $newUrl = null], [string $editUrl = null], [string $delUrl = null])

Constructor

For the three url parameters you should supply something like http:/myserver.com/modules/mymod/admin/tableprocess.php?op=edit&id= i.e they are absolute urls. Note trailing =. The value of column 0 (KeyId) will be suffixed to the url string before processing




Parameters:

array   $colNames   names of columns [0 => rowKeyName, 1 => Col1name .. n => Colnname]
string   $title   title of table if required
boolean   $dispKey   display the row key as first column. If false, you must still supply a column name as the first column in $colNames but it will be ignored and can safely be set to null or ''
string   $newUrl   url to redirect to add a new record
string   $editUrl   url to redirect to edit a record
string   $delUrl   url to redirect to delete a record

[ Top ]

method addRow [line 80]

void addRow( array $row)

Add a row of data to the table



Parameters:

array   $row   one row of data to display [0 => KeyId, 1 => Col1Data 2, n => ColnData]

[ Top ]

method addRows [line 100]

void addRows( array $rows)

Add multiple rows to table



Parameters:

array   $rows   [0>[item1,itemn],..]

[ Top ]

method display [line 112]

mixed display( [boolean $render = true])

output the table as html



Tags:

return:  string if $render = false, else void


Parameters:

boolean   $render   If true then echo html to output else return html to caller

[ Top ]


Documentation generated on Wed, 29 Mar 2006 14:01:54 +0100 by phpDocumentor 1.3.0RC3