CI_Table::clear()

clear() Returns: CI_Table instance (method chaining) Return type: CI_Table Lets you clear the table heading and row data. If you need to show multiple tables with different data you should to call this method after each table has been generated to clear the previous table information. Example: $this->load->library('table'); $this->table->set_heading('Name', 'Color', 'Size'); $this->table->add_row('Fred', 'Blue', 'Small'); $this->table->add_row('Mary', 'Red', 'Large

CI_Table::add_row()

add_row([$args = array()[, ...]]) Parameters: $args (mixed) – An array or multiple strings containing the row values Returns: CI_Table instance (method chaining) Return type: CI_Table Permits you to add a row to your table. You can submit an array or discrete params: $this->table->add_row('Blue', 'Red', 'Green'); $this->table->add_row(array('Blue', 'Red', 'Green')); If you would like to set an individual cell’s tag attributes, you can use an associative array for that

CI_Table

class CI_Table $function = NULL Allows you to specify a native PHP function or a valid function array object to be applied to all cell data. $this->load->library('table'); $this->table->set_heading('Name', 'Color', 'Size'); $this->table->add_row('Fred', '<strong>Blue</strong>', 'Small'); $this->table->function = 'htmlspecialchars'; echo $this->table->generate(); In the above example, all cell data would be ran through PHP’s htmlspecialchars() f

CI_Session::__set()

__set($key, $value) Parameters: $key (string) – Session item key $value (mixed) – Value to assign to the session item key Returns: void A magic method that allows you to assign items to $_SESSION by accessing them as $this->session properties: $this->session->foo = 'bar'; // Results in: // $_SESSION['foo'] = 'bar';

CI_Session::__get()

__get($key) Parameters: $key (string) – Session item key Returns: The requested session data item, or NULL if it doesn’t exist Return type: mixed A magic method that allows you to use $this->session->item instead of $_SESSION['item'], if that’s what you prefer. It will also return the session ID by calling session_id() if you try to access $this->session->session_id.

CI_Session::userdata()

userdata([$key = NULL]) Parameters: $key (mixed) – Session item key or NULL Returns: Value of the specified item key, or an array of all userdata Return type: mixed Gets the value for a specific $_SESSION item, or an array of all “userdata” items if not key was specified. Note This is a legacy method kept only for backwards compatibility with older applications. You should directly access $_SESSION instead.

CI_Session::unset_userdata()

unset_userdata($key) Parameters: $key (mixed) – Key for the session data item to unset, or an array of multiple keys Return type: void Unsets the specified key(s) from the $_SESSION superglobal. Note This is a legacy method kept only for backwards compatibility with older applications. It is just an alias for unset($_SESSION[$key]) - please use that instead.

CI_Session::unmark_temp()

unmark_temp($key) Parameters: $key (mixed) – Key to be un-marked as tempdata, or an array of multiple keys Return type: void Unmarks a $_SESSION item key (or multiple ones) as “tempdata”.

CI_Session::unmark_flash()

unmark_flash($key) Parameters: $key (mixed) – Key to be un-marked as flashdata, or an array of multiple keys Return type: void Unmarks a $_SESSION item key (or multiple ones) as “flashdata”.

CI_Session::tempdata()

tempdata([$key = NULL]) Parameters: $key (mixed) – Tempdata item key or NULL Returns: Value of the specified item key, or an array of all tempdata Return type: mixed Gets the value for a specific $_SESSION item that has been marked as “tempdata”, or an array of all “tempdata” items if no key was specified. Note This is a legacy method kept only for backwards compatibility with older applications. You should directly access $_SESSION instead.