Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fieldmanager_Hidden and htmlspecialchars warning #158

Closed
alexisbellido opened this issue Jun 23, 2014 · 1 comment
Closed

Fieldmanager_Hidden and htmlspecialchars warning #158

alexisbellido opened this issue Jun 23, 2014 · 1 comment
Assignees

Comments

@alexisbellido
Copy link
Contributor

When a Fieldmanager_Hidden field has no value, or a value equal to an empty string, the following warning is reported:

PHP Warning:  htmlspecialchars() expects parameter 1 to be string, array given in /var/www/.../wp-content/plugins/wordpress-fieldmanager/php/class-fieldmanager-hidden.php on line 28

I've worked around this by adding a check on the template before calling $form->element or by adding some dummy string value, like 'null', to the field in array of values returned by the fm_form_myform_values action.

@mboynes
Copy link
Contributor

mboynes commented Sep 1, 2014

I can't replicate this; is it still an issue for you?

@mboynes mboynes closed this as completed Jan 2, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants