Here’s what’s clogging up our logs:
]]>PHP Warning: Declaration of acf_field_validated_field::validate_field($valid, $value, $field, $input) should be compatible with acf_field::validate_field($field) in /home/public_html/wp-content/plugins/validated-field-for-acf/validated_field_v5.php on line 3
Since updating to ACP Pro 5.5.14, validated fields no longer retain their field names, and don’t display correctly or at all on the frontend.
The now randomly named fields do display on the backend, however, when using PHP regex validation they simply show up as <Name of Field> : Array instead of having a text box for typing in the field data.
My PHP regex code is still valid and unchanged from the prior version. The only thing that has changed is updating ACF Pro from a version prior to 5.5.x so I know the issue is a conflict between ACF and this validation plugin.
]]>Please correct, thanks!!!
Regards.
]]>validated_field_v5.php: Found a bug with ACF 5.5.2.
apply_filters( ‘acf/get_field_types’, array() );
This no longer return fields name. So need to replace this with acf_get_grouped_field_types() located in render_field_settings function.
Also need to update the dependency of ‘acf-validated-field-input’ in wp_register_script:
Old: array( ‘acf-validated-field’ )
New: array( ‘jquery’ )
Today I installed the latest update of ACF PRO (ver. 5.5.0) and unfortunately I realized that the name of a field which is associated with a “Validate Field” field no longer maintains the assigned name.
For example I have a field “postcode” and now the name has become “acf[field_573d88d0b925d]”.
I believe there is an incompatibility with the new version of ACF.
I hope you can solve quickly.
Regards!
]]>I have a repeater field that consists of:
Name | Email | Code | Value
The Code sub field is set to Validated Field / Text, with the option selected to force it to be unique, but it doesn’t seem to work properly.
This field is usually a number.
If I set “Unique Value” to Globally, when I try to save the field, it comes up as invalid and pulls the number out of a ton of places, like ” Date Created, Date Modified, Date Created, Date Modified, Date Created, Date Modified, Date Created, Date Modified, Date Created, Date Modified, Date Created, Date Modified, Date Created, Date Modified,” etc for many posts.
When I set the “Unique Value” to any other option, there are no validation errors, and I can save non-unique values.
Is this an issue because none of the other Unique Value options cover an ACF options page? If one of them should cover that case, which one? Or am I totally misunderstanding how things should work?
Thanks!
]]>I am having a weird PHP syntax error when I try to use the Validated Field for ACF plugin. I tried a simple return PHP code but still it has a syntax error and I am having a difficult time finding the error line in the PHP code because I have no idea where to search. It would be nice if you guys have some idea about this.
Please check links of the images:
https://postimg.org/image/plskfslt9/e4680500/
Hi,
I’ve this errors with your plugin and last ACFv5 version (5.4.6) :
JS Broken Dependencies
script: acf-validated-field-input https://localhost/site/wp-content/plugins/validated-field-for-acf/js/input.min.js
dependencie: acf-validated-field (missing)
version: 1.7.7
CSS Broken Dependencies
scripts: font-awesome https://localhost/site/wp-content/plugins/validated-field-for-acf/css/font-awesome/css/font-awesome.min.css
acf-validated_field https://localhost/site/wp-content/plugins/validated-field-for-acf/css/input.css
version: 4.2.0
To avoid this, I’ve removed ‘acf-validated-field’ and ‘acf-validated-field-input’ from wp_enqueue_script and all in input_admin_footer(), both in validated_field_v5.php
]]>Hi,
How could I compare a field with another input field.
eg. I have to compare 2 dates
thanks
Fred
after activating the plugin i can only see it the wp-admin menu under the acf tab. I don’t see any new validation field in my field group.
have a look here.
thanks
itamar
Hey, I use the image ACF field with validation turned on, and now I need to check it’s size. But that image field returns only the attachment ID. So first of all I need to get image URL and I use wp_get_attachment_image_src function for that. But the problem is that I can’t get anything from that function. Code I am trying to use is:
$img_src = wp_get_attachment_image_src($value, ‘full’).0;
return $img_src;
https://www.ads-software.com/plugins/validated-field-for-acf/
]]>Hi,
I am using this plugin to validate my few fields from ACF, but I also want to validate my Text field so that it can allow only URL pattern in particular text field, I just wanna know whether this plugin give such validation rule or not, if yes than how to implement this.
Thanks
Mayank
https://www.ads-software.com/plugins/validated-field-for-acf/
]]>The plugin does not appear after activation. ACF is active and working but the extra fields for validation do not appear.
Thanks,
Davide
https://www.ads-software.com/plugins/validated-field-for-acf/
]]>Hi,
Using the Advanced Custom Fields: Validated Field,
I created a uniqe field with pattern, and used a PHP statement for the validation. It validates a service ID:
all works greate!
my problem is – when I try to edit a service that contains that field, I get the error that the service ID already exists.
how do I disable the validation on editing post/service?
https://www.ads-software.com/plugins/validated-field-for-acf/
]]>Hi,
We’re building a membership only site. Members are issued with a Membership Cards prior to registration which have a number between 100000 and 160000. We’ve used your plug-in with ACF to add a ‘Validation Field’ to the registration form and the validation for the Number Field range works perfectly. However we also need the value to be unique, so that two Members cannot register with the same Membership number. We have selected ‘Unique Globally’ but this is not preventing multiple users registering with the same Membership Number.
Any help would be appreciated,
Miles
https://www.ads-software.com/plugins/validated-field-for-acf/
]]>Hi,
I installed this plugin today and can not find a panel where I can enter the validations to my fields .
I’m using the 5.3.7 version of ACF PRO .
Is there anything specific that I should turn to show these validations entry fields ?
https://www.ads-software.com/plugins/validated-field-for-acf/
]]>I have two repeater field date “start_date” and “end_date” is it possible to validate the “end_date” to be greater that the “start_date”?
Thanks in advance
https://www.ads-software.com/plugins/validated-field-for-acf/
]]>I’m looking for a way to validate a Dutch postal code which looks like this:
1111 AA
The first number can’t be 0 and I would like the letters to be capitals.
The following regex works in PHP, but nog when using the plugin:
~\A[1-9]\d{3} ?[a-zA-Z]{2}\z~
I would be quite happy if the case of the letters is checked (I’m not using 9999 aa as a temporary solution), but getting the regex to work would be the bomb.
https://nl.www.ads-software.com/plugins/validated-field-for-acf/
]]>Hello,
In my woocomerce shop i gave each product a custom field called “Service ID”.
We configured the validation to validate only in a specific letters+numbers pattern – this works fine – only this specific pattern is accepted as validated.
The issue is – we configured also unique globally but also when validating with the exact same string in 2 separated products all validates fine and the same value is entered twice to DB.
Not sure why.
Please assist.
A
https://www.ads-software.com/plugins/validated-field-for-acf/
]]>Apparently the plugin adds some inline JS to the <head>
in frontend, namely
<script type="text/javascript">
jQuery(document).ready(function(){
jQuery('form.acf-form').append('<input type="hidden" name="acf[post_ID]" value="541"/>');
jQuery('form.acf-form').append('<input type="hidden" name="acf[frontend]" value="true"/>');
});
</script>
However this can cause errors in situations when jQuery is not present in <head>
, f.e. if you deregister and reregister the shipped jquery version with the in_footer
option for performance reasons.
Could you add wrap your code in an if( window.jQuery ) { … } or even better: Only add it to pages with frontend forms (I guess the code is there for this feature?).
Or are there already hooks present to modify / disable the inline JS?
Thx!
https://www.ads-software.com/plugins/validated-field-for-acf/
]]>Using ACF pro 5.3.3.2 and WP4.4.1, I get many errors like the following with wp_debug turned on. Validation still works.
Notice: Undefined index: step in path-to-site/wp-content/plugins/advanced-custom-fields-pro/fields/number.php on line 75
The number of errors changes depending on field type. Refers to step, min, max, maxlength, prepend, append, placeholder.
https://www.ads-software.com/plugins/validated-field-for-acf/
]]>The subject says it all.
How to reproduce:
Activate this plugin. Try adding a tab field in an ACF field group. Result: nothing happens, the new field simply disappears.
Deactivate this plugin. Try doing the same thing again. Result: as expected, the tab field is created.
Inspecting the ajax call I can see the HTML from ACF is returned correctly. No JS errors in console. So there’s some sort of conflict somewhere.
https://www.ads-software.com/plugins/validated-field-for-acf/
]]>Hi.
From few weeks or few days, my client report me that the validation restriction (like required fields too) not working when a draft is saving. It’s working when I try to publish.
I verify the default behavior in the plugin options. It’s checked :
“Check this box to enable Draft validation globally, or uncheck to allow it to be set per field.”
I saw this problem was resolved one year ago :
https://www.ads-software.com/support/topic/validation-when-saving-draft?replies=3
The problem came back ?
]]>Hi, great add-on!
Just a question, how can I add only reading field value for each user?
For example: administrator create a “Payment” field (text) and inserts a value (different for each user), but user can’t modify it.
If I use “Read Only?” option I can’t insert different value for each users, right?
Thanks a lot!!!
https://www.ads-software.com/plugins/validated-field-for-acf/
]]>Hi,
I am looking for PIN / Product code validation only for single time. That means, my list of code will be stored and people can validate their product once only.
I have googled and found that https://www.astro-labs.net is using same plugin and functionality.
The purpose of this functionality is – users can validate their product authenticity and check if it related to firm or not. that too ONCE ONLY.
Suppose Mr. X comes to our website and put a given code say 000K90 on website- it will notify to Mr. X that their product has been authenticated. NOBODY CAN USE THAT CODE AGAIN including Mr. X.
I will really appreciate your help!
– rishabh
iNFOTYKE
https://www.ads-software.com/plugins/validated-field-for-acf/
]]>The repeater field is rendered in tables, but you are using a div to set the input mask selector. So, the mask isn’t working.
jQuery(function($){
$('div[data-field_key="my_field_key"] input').each( function(){
$(this).mask("my_mask", {
autoclear: true,
placeholder: '_'
});
});
});
https://www.ads-software.com/plugins/validated-field-for-acf/
]]>Is it possible validate comparing to the value of another field and how can I do that?
https://www.ads-software.com/plugins/validated-field-for-acf/
]]>hi,
I would like to calculate a date + x days, is this plug in can to that
i have an acf field date_from and i would like to display a date_to, but this code doesnt work (php statement)
//date From
$dateFrom= get_field(‘date_from’);
// month to add
$month = 2;
// transform
$dateFromTimestamp = strtotime($dateFrom);
// calcul (seems to be wrong)
$dateTo = date(‘d-m-Y’, strtotime(‘+’.$duree.’ month’, $dateFromTimestamp ));
// set the field
update_field( $date_to, $dateTo );
PS I M NOT A PHP PRO ??
Many thanks
https://www.ads-software.com/plugins/validated-field-for-acf/
]]>Hello!
I could not use the uniqueness for a Relation field!
Is this possible and how can i achieve it?
https://www.ads-software.com/plugins/validated-field-for-acf/
]]>Hi,
I have been having an issue with Validated Field. What I need is a Repeater/Flexible Content Field of Post Object Type which should be unique across my custom Post Type.
I have experienced all sorts of issues:
1. If I select Flexible Content validation fails when trying to edit a published post. The validation simply doesn’t care if it is the same post it will consider it not unique across post type. This is not the case with Repeater Field though.
2. When I select a validated field and select Post Object + Post Type it fails to show only the post type I want and shows all the Objects from all Post Types. This is the Major problem. Even if it works once after editing and updating the field it goes back to showing all Objects from all post types again.
I’m using ACF Pro 5.3.1 (previously ACF Pro 5.3.0) and latest version of ACF Validated Field.
I appreciate your help and thanks in advance.
https://www.ads-software.com/plugins/validated-field-for-acf/
]]>