Hello,
Thanks for getting in touch!
You can create some custom PHP logic to check if the entered value already exists on the database and display an error if it fails validation.
Here is a filter that you can use: https://www.advancedcustomfields.com/resources/acf-validate_value/
I hope this info helps. Thanks
Hi there,
Thanks for getting in touch.
Please create a new feature request here https://www.advancedcustomfields.com/contact/
Thank you.
Hi there,
Thanks for getting in touch!
I would suggest that you create an additional text field on the same field group and use this to add the class name that can be used on the page template when displaying the link field.
I hope this info helps.
Thank you.
Hi there,
Thanks for getting in touch!
Please try the solutions suggested on the following thread https://support.advancedcustomfields.com/forums/topic/set-wysiwyg-height/#post-51715
As for the gallery field feature request, please create a new ticket here: https://www.advancedcustomfields.com/contact/
I hope this info helps.
Thanks.
Hi there,
Thanks for getting in touch.
You can make use of the acf_reset_validation_errors() function to reset the current errors and then add some custom validation using this filter : https://www.advancedcustomfields.com/resources/acf-validate_save_post/
You can see how the validation works on line 12688 of acf-input.js
I hope this info helps. Thank you.
Hi there,
Your explanation is not very clear, you screenshot shows that you have a repeater field assigned to users, which posts would you like to see approved?
I am looking forward to helping you.
Hi @juanallona
Thanks for sharing the solution.
This will surely assist someone else in the same state.
Hi There,
Thanks for the mail.
Is it possible that your issue is related to the global post ID parameter?
Kindly try passing the global post ID param as the second parameter to the get_field function and let me know you are able to load the value.
Hope to hear from you soon.
Hi @lightsage88
It’s most likely that you are trying to load the field values before they are actually saved into the database.
Kindly try changing the priority of the ‘woocommerce_email_after_order_table’ to above 10 to see if you are able to load the field.
Hope to hear from you soon.
Hi There,
Thanks for reaching out to us.
For such an implementation, I would recommend that you make use of the get_fields function.
https://www.advancedcustomfields.com/resources/get_fields/
This function will return an array of all the field and value related to a specific post.
You can then implement some code to filter and only return values for the image field type.
Hope this helps.
Hi @pjeaje
Your question is not quite clear.
Are you looking at adding the value to the main content?
If that’s the case, you can hook onto the acf/save_post filter to access the submitted value and update the main post content here.
https://www.advancedcustomfields.com/resources/acf-save_post/
Let me know how it goes.
Hi @vgledhill
Thanks for reaching out to us.
Kindly try switching your code as following and let me know how it goes.
`<?php
if(is_int(get_field(‘ohj_height’))) {
echo “OHJ”; the_field(‘ohj_height’);
}
?>’
Hope to hear from you soon.
Hi There,
Thanks for reaching out to us.
Are you using an ACF taxonomy field? if that’s the case, then you can easily use the get_field function to return the taxonomy and display it without a link.
Alternatively, you can also make use of the WP get_terms function which returns the term as opposed to displaying it on the screen.
https://developer.wordpress.org/reference/functions/get_terms/
Hope this helps.
Hi @jlgouwy
Thanks for reaching out to us.
Here is a simple solution that should work for such a setup.
https://gist.github.com/senlin/4fd15ba7a19533ceb9fe
Let me know how it goes.
Hi @rgdesign
Apologies for the delay.
Are you still having issues with the plugin?
Kindly share some more details of your setup so that I may be able to advise further.
Hope to hear from you soon.
Kindly confirm which version of the plugin are you using?
You will need to use the beta version (5.8 beta3) to test out the blocks as the version is not officially release.
Hope to hear from you soon.
Hi @gavin310
Thanks a bundle for the request.
I am going to mark for the developer’s consideration.
In the meantime, you may also consider adding some custom CSS to increase the margin.
Hope this helps.
Hi @nicolasg
This could suggest that the acf_form_head() si not working as expected.
Can you confirm that this is set to load as the first function on the page template?
This is possible, please refer to this older thread https://support.advancedcustomfields.com/forums/topic/first-image-of-gallery-only/
Hi @rallred
Which version of the plugin did you install?
ACF has some field types which are only available as premium addons, this include the repeater field, flexible content field, the gallery fied as well as the options page.
Additionally, there are several field types such as the link which were added in later version (5.6)
Kindly be sure to use the latest version and if you do not have access to the PRO version, you may try out upgrading to the free version 5 as described here.
https://www.advancedcustomfields.com/resources/upgrade-guide-version-5/
Hope this helps.
You will need to check the repeater row count as follows.
$count = count(get_field('repeater_name'));
You can then show the each code set depending on the row count.
Hope this helps.
Hi @mrt
I am afraid there is no other approach from the API apart from updating the postmeta records from the database.
You would need to update the wp_postmeta table to change the keys from the old one to the new one.
However, this will only work for simple fields such as text fields. As for repeater sub fields and flexible content sub fields, you will need to modify the specific field key modifield considering the repeater name as well.
Hope this helps.
Hi @carllwyman
Unfortunately, I am afraid that is currently not the case because of how ACF saved the field values.
ACF saves the field values as post/user meta records. By setting the fields default value, this will auto load the value when editing the user records however, this does not update the records’ meta value.
As an approach, you would need to loop through updating the values using the update_field method.
Hope this helps.
Kindly share some more details of your setup.
1. Which version of the plugin are you using?
2. What are your datepicker field configurations?
3. How are you loading the values on the map?
Hope to hear from you soon.
I am afraid the get_field/the_field expects a second parameter for the post ID otherwise the global post ID values is used.
Try changing the code as follows and let me know how it goes.
$service_name = get_field('service_name', $post_id);
$customer_name = get_field('customer_name', $post_id); // where $post_id is the post ID from which you are loading the ACF value.
Hope this helps.
Welcome to the Advanced Custom Fields community forum.
Browse through ideas, snippets of code, questions and answers between fellow ACF users
Helping others is a great way to earn karma, gain badges and help ACF development!
We use cookies to offer you a better browsing experience, analyze site traffic and personalize content. Read about how we use cookies and how you can control them in our Privacy Policy. If you continue to use this site, you consent to our use of cookies.