Example: Set the current date for the date object "date_issued"
Code: Select all
function nuOnProcessObjects() {
for ($i = 0; $i < count($f->objects); $i++) {
if ($f->objects[$i]->id == 'date_issued' && $f->objects[$i]->value == '') {
$f->objects[$i]->value = date('Y-m-d');
break;
}
}
}