0

I am using the freeform_module_admin_notification hook and the documentation indicates that the field contents should be available:

$this->fields (array) - output data of fields by fieldname

But the fields array contains the 'Field Label' of the field keyed by the Field Name.Not the value entered in the form by the user.

For example I have defined a text field in the admin panel for the module, it is called 'name' and the Field Label is 'Name' I have included it on a form:

<input type="text" id="name" name="name" class="input-1" />

But the value I get within the extension is 'Name' not the value entered in the field.

$fields['name'] has a value of Name

Anyone any idea if this is a bug or I am just doing something wrong?

Thanks

Andrew

0

I believe you want to look at $variables, not $fields - specifically, $variables['field_inputs'] and/or $variables['field_outputs']

|improve this answer|||||

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.