• Resolved sugardaddy

    (@sugardaddy)


    Hi,
    I’ve created an option page for a CPT and it doesn’t show up in the menu of the CPT.
    I realized I had to insert the php in the functions file (but I’m not sure as it’s not obvious at all). But still the issue : no option page.
    Thanks a lot for your help.

Viewing 5 replies - 1 through 5 (of 5 total)
  • Thread Starter sugardaddy

    (@sugardaddy)

    I figured out the issue by myself.
    We can’t simply add the slug of the parent.
    I had to use “edit.php?post_type=slug” where slug is my CPT slug.
    Maybe because it’s a CPT?

    • This reply was modified 2 years, 3 months ago by sugardaddy.
    Thread Starter sugardaddy

    (@sugardaddy)

    Well I can’t figure how it’s supposed to work.
    Settings are fine but how the option page is translated? How to setup the fields group to the correct language? There’s a lack of documentation for this feature (Polylang compatibility).
    So… thanks for any help on this!

    Thread Starter sugardaddy

    (@sugardaddy)

    My goal is to have my fields translated.
    Today I have all the fields groups into the same option page and the fields are mysterioulsy synchronized even if the translations option is set to “translate”.

    Thread Starter sugardaddy

    (@sugardaddy)

    OK so I found how it works.
    And I’m sorry it’s not related to this plugin.
    This was related to “ACF Options for Polylang” plugin which is working weirdly but it’s working.

    Plugin Author Konrad Chmielewski

    (@hwk-fr)

    Hello,

    Thanks for the feedback, and sorry for the late answer, I’m kinda busy with the upcoming patch lately.

    The ACF Extended Options Page Module is just an UI to register ACF Options Page that use the native acf_add_options_page() behind the scene (see documentation).

    This is why there is no documenation for each setting, as those are described in the ACF documentation.

    Regarding the ability to display an Options Page under a post type, you guessed it right, you have to use the admin url such as edit.php?post_type=slug in the “Parent” setting. This follow the logic of the native WordPress add_submenu_page() logic (see documentation).

    Regarding the translation of the Options Page, ACF Extended has a compatibility module with Polylang (see documentation).

    This means that if you registered an options page with the post id my-options, it will automatically save/display values under the post id my-options-fr_FR for the french language.

    You can see what meta data are saved using the Developer Mode. This will display options meta, and their translations, in your Options Page admin.

    On the front-end, your code remain the same. In order to display a value, you can use the following vode:

    echo get_field('my_field', 'my-options');
    

    ACF Extended will automatically use my-options-fr_FR if the user is viewing the site in french language.

    Hope it helps!

    Have a nice day!

    Regards.

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Options page not showing’ is closed to new replies.