WordPress.org

Ready to get started?Download WordPress

Plugin Directory

Advanced Custom Fields: Validated Field

The Validated Field add-on for Advanced Custom Fields provides input masking and validation of other field types.

1.3.1

  • Bug Fix: Apply input masking to fields for new posts, not just editing existing ones.

1.3

  • Support front end validation using acf_form().
  • Support for WPML, props @gunnyst.
  • Move configuration to WordPress Admin under Custom Fields > Validated Field Settings.
    • Debug - enable debugging, defaults to off.
    • Drafts - enable draft validation, defaults to on.
    • Front End - enable front end validation, defaults to off.
    • Front End Admin CSS - enable acf_form_head() to enqueue an admin theme, defaults to on.
  • Improved SQL for unique queries to support Relationship fields - check both arrays and single IDs.
  • Fix conflicts with ACF client side validation (required fields, etc).
  • Fix reference to $sub_field['read_only'] with $field['read_only'] for jQuery masking, props @johnny_br.

1.2.7

  • Bug Fix: Post Preview fix when WordPress 'click' event triggers a 'submit' before the clicked element can be tracked by the plugin.
  • Added comments to unpacked JavaScript.

1.2.6

  • Critical Bug Fix: Fix compatibility issues with Firefox.

1.2.5.1

  • Remove debug error_log() statement from v1.2.5.

1.2.5

  • Finish text localization, include es_ES translation.
  • Pack and compress validation javascript.
  • Bug Fix: prevent PHP array index notice for non-repeater fields.
  • Code formatting.

1.2.3

  • Support for globally bypassing Draft/Preview validation by setting ACF_VF_DRAFTS to false.
  • Support for bypassing Draft/Preview validation per field (defaults to validate).
  • Bug fixes: properly hide Draft spinner, cleaned up JavaScript.

1.2.2

  • Properly include plugin version number on JavaScript enqueue for caching and PHP notices.
  • Use minified JavaScript unless ACF_VF_DEBUG is set to true.
  • Tested up to WordPress 3.9.1

1.2.1

  • Show 'Validation Failed' message in header as needed.
  • Mark form as dirty when input element values change.
  • Fix return of $message from field configuration to UI.

1.2

  • Support for Repeater Field Validated Fields.
  • Support for debugging with ACF_VF_DEBUG constant.
  • Clean up variable names, more code standardization.
  • Better handling of required fields with validation.

1.1.1.1

  • Remove debug error_log() statement from v1.1.1.

1.1.1

  • Clean up PHP to WordPress standards.
  • Fix PHP Notice breaking AJAX call.
  • Use defaults to prevent invalid array indexes.
  • Update JavaScript for UI Errors.
  • More localization prep for text.

1.1

  • Add Read-only functionality (beta).
  • Use standard ACF error/messaging.
  • Correctly process "preview" clicks, fixes error where the post would be published.
  • Register CSS only in required locations.
  • Properly apply subfield filters for acf/load_value/type=, acf/update_value/type=, acf/format_value/type=, acf/format_value_for_api/type=, acf/load_field/type=, acf/update_field/type=.
  • Tested up to WordPress 3.9.

1.0.7

  • Critical bug fix for selecting Validated Field type.

1.0.6

  • Bug fix $sub_field properties not saving (use acf/create_field_options action).
  • Bug fix multiple Validated Fields in a set - correct to always use unique selectors.
  • Allow for unique query to be run on selected post statuses.
  • Set default statuses included in unique queries with filter of acf_vf/unique_statuses.
  • Remove redundant table wrapper on validated fields.
  • Clean up potential strict PHP warnings.

1.0.5

  • Hide spinner for update if a validation error is encountered.
  • Allow for uniqueness queries to apply to only published or all post statuses.
  • Clean up debugging code writing to the error log for regex validations.

1.0.4

  • Fix javascript error when including ace.js, props @nikademo.
  • Fix "Undefined index" PHP notice, props @ikivanov.

1.0.3

  • Bug fix for unique field values per post_type. Props @ikivanov.

1.0.2

  • Bug fix for editing a validated field. Ensure proper type is selected and UI refresh is triggered. Props @fab4_33.

1.0.1

  • Clean up strict warnings

1.0

  • Update for compatibility with Advanced Custom Fields 4+
  • Implement ace.js for syntax highlighting

0.1

  • Initial version.

Requires: 3.0 or higher
Compatible up to: 3.9.1
Last Updated: 2014-7-24
Downloads: 2,516

Ratings

5 stars
5 out of 5 stars

Support

6 of 7 support threads in the last two months have been resolved.

Got something to say? Need help?

Compatibility

+
=
Not enough data

1 person says it works.
0 people say it's broken.

100,2,2
100,1,1
100,1,1
0,1,0 100,1,1
100,1,1
100,2,2 100,1,1 100,1,1 100,1,1 100,1,1 100,1,1 100,1,1 100,1,1 100,1,1 100,1,1
100,1,1 100,1,1 100,1,1
100,1,1 100,1,1
100,1,1 100,1,1
100,2,2 100,1,1 100,2,2 100,1,1 100,1,1