Support

Account

Home Forums Backend Issues (wp-admin) ACF PRO selection field has no title

Solved

ACF PRO selection field has no title

  • Since a short time I am not seeing any text in my ACF PRO rules field. I have no idea where I should start to debug this.

    WP: 5.3.2
    Timber: 1.14.0
    ACF PRO: 5.8.7
    No other plugins.

    Backend Issue

  • Please check if the text is actually missing from the DOM, or if the text exists but is not displayed for whatever reason. That will give us some direction.
    Do you know how to go about this?

  • It is actually missing. I did not alter the code in any way. So there isn’t a ” ” (space) in there. It’s simply empty.

    <select id="acf_field_group-location-group_0-rule_0-value" class="" name="acf_field_group[location][group_0][rule_0][value]" data-ui="0" data-ajax="0" data-multiple="0" data-placeholder="Auswählen" data-allow_null="0">
     <option value="acf-options-gobal-settings"></option>
     <option value="acf-options-multilingual-settings"></option>
     <option value="acf-options-post-teaser"></option>
     <option value="acf-options-hero-header" selected="selected" data-i="0"></option>
     <option value="acf-options-featured-sites"></option>
     <option value="acf-options-news"></option>
     <option value="acf-options-events"></option>
     <option value="acf-options-classic-layout">Pagestyle: Classic Layout</option>
     <option value="timber-bulma-documentation">Documentation</option><option value="calendar-api">Calendar API</option>
    </select>
  • I got to mention that this is only the case for the Options-Seite (Options-Page).

  • So far so good. Then it is definitely not a browser issue and not a CSS issue. Have you checked the code that registers the options pages? Perhaps strings are missing, or if they are wrapped in localization functions, such as __(), the translation is missing.

  • I already switched the backend to english, and they are still missing. So by my understanding that can’t be the problem.

  • Don’t think this will help, but this is my entire Options Registration PHP file.

    if( function_exists('acf_add_options_page') ) {
    
    	acf_add_options_page(array(
    		'page_title' 	=> 'General Template Options',
    		'menu_title'	=> 'General Template Options',
    		'menu_slug' 	=> 'general-template-options',
    	));
    	acf_add_options_sub_page(array(
    		'menu_title'	=> 'Gobal Settings',
    		'parent_slug'	=> 'general-template-options',
    	));
    	acf_add_options_sub_page(array(
    		'menu_title'	=> 'Multilingual Settings',
    		'parent_slug'	=> 'general-template-options',
    	));
    //	acf_add_options_sub_page(array(
    //		'menu_title'	=> 'Hero Header',
    //		'parent_slug'	=> 'General Template Options',
    //	));
    	acf_add_options_sub_page(array(
    		'menu_title'	=> 'Post Teaser',
    		'parent_slug'	=> 'general-template-options',
    	));
    
    	acf_add_options_page(array(
    		'page_title' 	=> 'Front Page Options',
    		'menu_title'	=> 'Front Page Options',
    		'menu_slug' 	=> 'front-page-options',
    	));
    	acf_add_options_sub_page(array(
    		'menu_title'	=> 'Hero Header',
    		'parent_slug'	=> 'front-page-options',
    	));
    	acf_add_options_sub_page(array(
    		'menu_title'	=> 'Featured Sites',
    		'parent_slug'	=> 'front-page-options',
    	));
    	acf_add_options_sub_page(array(
    		'menu_title'	=> 'News',
    		'parent_slug'	=> 'front-page-options',
    	));
    	acf_add_options_sub_page(array(
    		'menu_title'	=> 'Events',
    		'parent_slug'	=> 'front-page-options',
    	));
    
    	acf_add_options_page(array(
    		'page_title' 	=> 'Page Template Settings',
    		'menu_title'	=> 'Page Template Settings',
    		'menu_slug' 	=> 'page-template-settings',
    		'capability'	=> 'edit_posts',
    		'redirect'		=> true
    	));
    	acf_add_options_sub_page(array(
    		'page_title' 	=> 'Pagestyle: Classic Layout',
    		'menu_title'	=> 'Classic Layout',
    		'parent_slug'	=> 'page-template-settings',
    	));
    	acf_add_options_page(array(
    		'page_title' 	=> 'Documentation',
    		'menu_title'	=> 'Timber Bulma Documentation',
    		'menu_slug' 	=> 'timber-bulma-documentation',
    		'capability'	=> 'edit_posts',
    		'redirect'		=> true
    	));
    	acf_add_options_page(array(
    		'page_title' 	=> 'Calendar API',
    		'menu_title'	=> 'Calendar API',
    		'menu_slug' 	=> 'calendar-api',
    		'redirect'		=> true
    	));
    }
  • The three options pages, that are displayed, are all endpoints of explicit redirects.

    • “Page Template Settings” is missing, but it redirects to “Pagestyle: Classic Layout,” which is printed.
    • “Documentation” redirects to a subpage, but there are none, so it is printed.
    • “Calendar API,” too, redirects to a subpage, but there are none, so it is printed.

    I do not know what to make of it though.

  • Me neither.
    Off topic – but i have forgotten to remove Calendar API.

    What can I do to further troubleshoot this?

  • Try explicitly declaring 'redirect' => true/false on all pages. Just a hunch, but, who knows?

  • Yep, nope. That didn’t change anything.

  • If you are interested, I can send you my functions files.

  • I do not mind taking a look, but you should know that I will be out of office for a week or longer. Do not count on me if you happen to be in a hurry.

  • All of the ones that are not appearing do not have “page_title” defined.

  • I cannot comprehend how we managed to overlook this.

  • Me neither. That’s most likely the solution. Will test it monday, then confirm.

  • Sorry, working on another project right now. I’ll do it as soon as possible and give feedback. Promised() !

  • This did solve the issue. Sorry forgot to respond.
    resolved(); !

Viewing 19 posts - 1 through 19 (of 19 total)

The topic ‘ACF PRO selection field has no title’ is closed to new replies.