array('post', 'string', ''), ); getFields($fields); $fields = $oci->oci_form_fields($application); getFields($fields); $all_vars = get_defined_vars(); $oci_vars = array(); foreach ($all_vars as $name => $value) { if (in_array($name, array_keys($fields))) { $oci_vars[$name] = $value; } } if (!$application) { __('No application chosen.'); include_once('foot.php'); exit(); } if (!$oci->app_is_installable($application)) { __('Application not supported: '); print(ehe($application)); include_once('foot.php'); exit(); } // @TODO validations $errors = $oci->oci_form_validate($oci_vars); if (!empty($errors)) { print('
'); print('

' . _('Validation Errors') . '

'); print('
' . count($errors) . ' ' . _('validation errors in form') . '
'); foreach ($errors as $delta => $error) { printf('
%s : %s', $error['module'], $error['message']); if (isset($error['data'])) { print('
'); foreach ($error['data'] as $name => $value) { printf('
%s
', $name); printf('
%s
', htmlentities(print_r($value, TRUE))); } print('
'); } print('
'); } print('
'); include_once('foot.php'); exit(); } ?>

'); foreach($oci_vars as $name => $value) { print("
$name
"); if (isset($value)) { $a = htmlentities($value); } else { $a = "***" . __('undefined') . '***'; } print("
$a
"); } print(''); ?>

$value) { printf('', $name, $value); } ?>