SproutCMS

This is the code documentation for the SproutCMS project

function collateFieldData()

Collates a single field's $_POST data for INSERT/UPDATE queries, and performs validation

Usage

void JsonForm::collateFieldData ( array $field_defn , string $input , array $metadata , Validator $valid , array &$data );

Arguments

  1. array $field_defn
    Field definition from JSON file
  2. string $input
    The POSTed input for the field, usually just from $_POST[field_name]
  3. array $metadata
  4. Validator $valid
    &$data Data for DB insert/update
  5. array $data (by reference)

Return value

  • void