Input and Output Controls - define how a field is rendered

Input and Output Controls are associative arrays used to define how to render input or output for a field. Inputs render form inputs like: text, checkbox, radio, etc. Outputs render: text, links, and images.

Example:
$lm->after_insert_user_function = 'my_after_insert';
function my_after_insert($id){
// after_insert_user_function is the only action to get the identity id
// now that the record is added we can do anything we need to
global $lm;
$sql_param = array(':market_id' => $id);
$sql = "insert into related_table(field1, market_id) values (now(), :market_id)";
$lm->query($sql, $sql_param);
}

Cross Site Request Forgery - csrf

This script does not validate csrf itself but has a placeholder csrf variable from loaded from $_SESSION['_csrf']. To protect from csrf, place your nonce token in $_SESSION['_csrf'] and validate the csrf on POST commands.