For others who have this problem – when it happens for me, deactivating then reactivating the licence key seems to work, and I can then update the plugin.
hope that helps someone,
I’m having a similar issue but not sure whether it’s the same.
2 Repeaters on an options page, both seem to work fine to start with, then show empty after saving values and clicking the Add Row button doesn’t do anything – is that the behaviour you’re seeing?
Thanks John, I’ll take a look and see if there’s something non-intrusive I could do to add this functionality soon as I get a mo.
I think I can see why it’s not likely to get added, but if I can add what I need I’m happy either way.
There isn’t a way I know of to display all fields other than running a query on the wp_postmeta table yourself and discerning what’s an ACF field and what isn’t by testing or joining to the wp_posts table.
But, if you have a particular ID of a page or post or options page that you want to get the custom fields for, you can use
get_field_objects($postID); to get an array of fields along with various details about each field.
You can then loop through them and use
get_field('field_name', $postID); to get the value of a particular field if you need to show values too.
I recently needed to do something similar to generate a ‘report’ which listed all custom fields and exported to a .csv – to do this, I first created a draft post with all custom fields filled in, saved it & used
get_field_objects() for this post. I then took the resulting array & looped through it for each of the other posts to get the data. Perhaps not the most efficient way but it works.
Hope this helps
thanks for replying to this thread – in the meantime I had adopted ACF PRO but was just manually importing a JSON file for each new site.
Being able to sync these is something I didn’t know about, thanks for the link – just tried it out and it worked great. I think I can live with it now 🙂
To load the custom js I hooked into acf/input/admin_head, the docs here explain how to do that pretty well: http://www.advancedcustomfields.com/resources/acfinputadmin_head/
After that it was just vanilla jQuery to do the heavy lifting.
Hope that helps
EDIT – unfortunately my code is pretty specific to the fields and post types involved so what I’ve written isn’t something you could really copypasta into your own project – but hiding / showing divs using jQuery is something you’ll be able to find plenty of help with online.
The only difficult part is finding out what the IDs of the fields and containing divs are, you’ll need to spend some time in Firebug to get an idea about what to target.
I’d like to add my vote for this… would be very very useful for a site I’m working on now. I’ll roll my own in the meantime – elliot, thanks so much for your hard work on what is without a doubt the most useful and innovative plugin in existence. Share the love!
Do you get expected output if you use wpautop?
It’s one of the functions that gets run on the ‘the_content’ filter, you can also do:
echo apply_filters('the_content', $curauth->user_bio);
Which will sort out shortcodes and other things.
I don’t think has anything to do with ACF, but I’m playing around with custom user fields at the moment so I’ll follow up if I find anything.
Thanks @elliot, to your credit this is the only bug I’ve ever found in more than a year of using your plugins – great work and thankyou 🙂
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!
Considering recording another "Building a Custom x Block in y minutes with ACF” screencast.— Advanced Custom Fields (@wp_acf) February 26, 2020
🗣 What type of block would be of interest to you?
© 2020 Advanced Custom Fields. Subscribe