Closed stevenkword closed 10 years ago
I'm not against merging this in if it's needed. However, if you need to add input fields to the form, I would suggest using the 'lift_form_filters' to add the fields so you can arrange them as needed, and then using the 'lift_formfield' . $field filter to add in the field. That way you know you're getting the correct prefix/postfix for the field if another plugin tries to change the styling.
My goal is to create the ability to add hidden input fields to the lift search form. I have an application where I want to have both the lift_search_form() and the default WordPress search form on the same page and. Since both search forms use the s
query var, I need to create a hidden field to determine origin and then process appropriately. Perhaps we should rename it and add a comment that mentions the proper method for adding normal fields?
lift_form_add_hidden_fields
Adds two new filter hooks,
lift_form_before_fields
andlift_form_after_fields
. These hooks are intended to be used for rendering additional input fields in the lift search form.