DB2 PHP Generator online Help
Prev | Return to chapter overview | Next |
GetEnvVar
Returns the value of a specified environment variable.
Signature:
function GetEnvVar($name)
Example:
The following example demonstrates how to use variables within the OnBeforeInsertRecord event handler.
$rowData['ip_address'] = $this->GetEnvVar('REMOTE_ADDR');
$userName = $this->GetEnvVar('CURRENT_USER_NAME');
if ($userName != 'admin')
$rowData['changed_by'] = $userName;
Prev | Return to chapter overview | Next |