Controller Fields For Contact Form 7 Wordpress Plugin - Rating, Reviews, Demo & Download
Plugin Description
Contact Form 7 is an excellent WordPress plugin and one of the top choices of free WordPress plugins for contact forms. Controller Fields makes it even more awesome by adding dynamic content capabilities. This plugin provides new form tags for select fields, checkboxes, and radio buttons so you can use them to control the display of other fields and content. Some examples might include:
- Hiding or revealing additional form fields based the current value in a dropdown
- Hiding or revealing content when users click a checkbox
- Hiding or revealing information based on which radio button is currently selected
- Controllers and controlled fields can be nested
The possibilities are endless!
WHAT DOES IT DO?
This plugin creates three (3) new form tags for controlling the appearance of other form tags (aka “controller”) and a special form tag generator button to output the HTML needed to wrap the controllable form tags inside.
HOW TO USE IT
After installing and activating the plugin, you will have four (4) new buttons at the top when creating or editing a Contact Form 7 form: select controller, checkbox controller, radio controller, and controlled form tag wrapper. Most of the options in their tag generators will be familiar to Contact Form 7 users but there have been some upgrades.
Id Attribute
The frontend script relies on unique IDs for the controller form tags, so be sure to always set one!
Options
There are three (3) ways you can define your options. The first method is simply typing your options with each one on a new line, e.g.:
Apples Bananas Dragonfruit
The second method is similar, but it allows you more control over the value and label by using |
to separate them, e.g.:
fruit_1 | Apples fruit_2 | Bananas fruit_3 | Dragonfruit
The third method is dynamic in that you can use a shortcode to populate your options with two important provisions:
- The shortcode should NOT include the normal square brackets (
[
and]
). So, instead of[my_shortcode key='value']
you would usemy_shortcode key='value'
. - Any parameters in the shortcode must use single quotes. That is:
my_shortcode key='value'
and notmy_shortcode key="value"
Shortcodes used here should return a string value with the option or option group HTML.
Default value
This field can take static text or a shortcode. If using a shortcode, the same syntax applies from the options field. However, this field also has a few more needs:
- The text/shortcode must first have apostrophes converted to it’s HTML entity code,
'
- After that, it must be URL encoded so that spaces become
%20
and other non-alphanumeric characters are converted.
Placeholder
Only available for the select controller form tag, this field can take static text or a shortcode. If using a shortcode, the same syntax applies from the options field. However, this field also has a few more needs:
- The text/shortcode must first have apostrophes converted to it’s HTML entity code,
'
- After that, it must be URL encoded so that spaces become
%20
and other non-alphanumeric characters are converted.
Read Only Attribute
Simply check this box if you do not want to let users edit this field. It will add the readonly
attribute to your form field.
Disabled Attribute
Simply check this box if you do not want to submit this field in the form. It will add the disabled
attribute to your form field.
Screenshots
No screenshots provided