Title: Value validation function problem
Last modified: August 31, 2016

---

# Value validation function problem

 *  [iandor](https://wordpress.org/support/users/iandor/)
 * (@iandor)
 * [10 years, 1 month ago](https://wordpress.org/support/topic/value-validation-function-problem/)
 * Hayhay!
 * The `"Autocomplete value seems invalid."` function isn’t in the code, just the
   message.
 * If you add a `"Label|Value"` datas to field and enter text out of list then the
   value will be valid and the value will be the text.
    It’s wrong for me. e.g. 
   the valid data is `"python|11"` and the text is `asm` then the value will be `
   asm` but i need a number
 * In _cf7-autocomplete.php_ file at _Line 88_ after
 *     ```
       source: <?php echo json_encode($value); ?>
       ```
   
 * with comma i add this code:
 *     ```
       autoFocus: true,
       change: function (event, ui) {
       	if (!ui.item) {
       		this.value = "";
       	}
       }
       ```
   
 * It’s good for me but not optional…
 * [https://wordpress.org/plugins/contact-form7-autocomplete/](https://wordpress.org/plugins/contact-form7-autocomplete/)

The topic ‘Value validation function problem’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/contact-form7-autocomplete_9ba386.
   svg)
 * [Contact Form7: Autocomplete](https://wordpress.org/plugins/contact-form7-autocomplete/)
 * [Support Threads](https://wordpress.org/support/plugin/contact-form7-autocomplete/)
 * [Active Topics](https://wordpress.org/support/plugin/contact-form7-autocomplete/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/contact-form7-autocomplete/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/contact-form7-autocomplete/reviews/)

## Tags

 * [validation](https://wordpress.org/support/topic-tag/validation/)
 * [value](https://wordpress.org/support/topic-tag/value/)

 * 0 replies
 * 1 participant
 * Last reply from: [iandor](https://wordpress.org/support/users/iandor/)
 * Last activity: [10 years, 1 month ago](https://wordpress.org/support/topic/value-validation-function-problem/)
 * Status: not resolved