Hello guys I have a question with pages options ACF, and I do not know how to fix it.
Basically I built three different pages
– THEME OPTIONS (30 fields)
– SOCIAL OPTIONS (5 fields)
– EXTRA OPTIONS (7 courses)
I noticed that when acf save a page options, and as if was managing at the same time all three pages.
I would like, not to overload the server, each page is saved individually.
I read this post, but it is not very experienced with PHP does not know how to do
http://support.advancedcustomfields.com/forums/topic/acfsave_post-for-specific-options-page/
The user has been very kind, but I was not able to replicate his suggestion. And ‘possible to have some practical real case?
My page Option is this code:
// DEFINISCE PAGINE OPZIONI ACF
if( function_exists('acf_add_options_page') ) {
// PAGINA CONTATTI RISTORANTE
acf_add_options_page(array(
'page_title' => __('Contatti e Social','chickrestaurant'),
'menu_title' => __('Contatti e Social','chickrestaurant'),
'menu_slug' => 'contatti-restaurant',
'position' => 181
));
// PAGINA SOCIAL RISTORANTE
acf_add_options_page(array(
'page_title' => __('Servizi Extra','chickrestaurant'),
'menu_title' => __('Servizi Extra','chickrestaurant'),
'menu_slug' => 'social-restaurant',
'position' => 182
));
// PAGINA DESIGN RISTORANTE
acf_add_options_page(array(
'page_title' => __('Identità Ristorante','chickrestaurant'),
'menu_title' => __('Design Ristorante','chickrestaurant'),
'menu_slug' => 'setting-restaurant',
'capability' => 'manage_options',
'position' => 187
));
}
Thank you very much,
Davide
As far as I know ACF only submits and updates the values associated with the field groups that are attached to the options page being saved, it does not submit and save all of the options on all of the options pages.
Why do you think this is happening?
Unfortunately not, the options pages are managed and saved all together. If I for example I have 4 options pages, these pages will be saved and analyzed simultaneously.
I’m a little lost about what you mean. The only values that are being saved are for one options page. All of the fields from other options pages are not submitted when you update an options page. You’ll need to explain further what it is that you’re doing… are you trying to detect in a save_post function which options page is being saved.
The topic ‘Problem save page option’ is closed to new replies.
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.