Error “Selected value does not exist”
-
Hi, I have been using the plugin and its pretty great but recently I have always had problems every time the plugin got updated.
And I have been dynamically filling in select options with values linking to Id’s and my options/labels Showing the name of the item. For example
<option value="${value.id}">${value.client_name}</option>
But then when I submit, I get this error ‘Selected value does not exist’.
So what i have been doing is commenting out the
if ( ! $value_exists ) { $this->validation_message[ $id ] = apply_filters( 'forminator_select_field_nonexistent_validation_message', esc_html__( 'Selected value does not exist.', 'forminator' ), $id, $field ); }
code in the validate( $field, $data ) function of library/fields/select.php
every time but it gets overwritten every time the plugin updates.
Will there be future support to turn it off? Is there a way to overwrite this function? Should i be using the prefill functionality? Should I use filters or creating a child plugin? I’m still new to WordPress development so any help is greatly appreciated!
I even tried turning off the forminator updates but it seems to always still get updated no matter what, because even my theme is overwritting my functions.php.
Thanks
- The topic ‘Error “Selected value does not exist”’ is closed to new replies.