WordPress.org

Ready to get started?Download WordPress

Forums

Theme-Check
[resolved] Error add_options_page (5 posts)

  1. iLen
    Member
    Posted 1 month ago #

    Hello, because the function of adding menu add_options_page send error, should also allow this functionality. But this tells me is wrong and will not let me pass the review.

    https://wordpress.org/plugins/theme-check/

  2. Samuel Wood (Otto)
    Tech Ninja
    Plugin Author

    Posted 1 month ago #

    This is not an error, this is a correct message. Themes should use the add_theme_page function instead.

    The add_options_page function is for adding pages to the settings menu, themes should add their pages under the Appearance menu.

  3. iLen
    Member
    Posted 1 month ago #

    I do not think this logic response because within a WordPress Theme you can create new pages and plugin need to be add_options_page, is an error that the plugin does not accept this option.

  4. Samuel Wood (Otto)
    Tech Ninja
    Plugin Author

    Posted 1 month ago #

    It is not an error, it is intentional. Themes are not allowed to use the add_options_page function, as per the theme review guidelines.

    http://make.wordpress.org/themes/guidelines/guidelines-theme-check/

    Themes are required to use the add_theme_page() function to add the Theme Settings Page to the Appearance menu, rather than using add_menu_page() to add a top-level menu.

    The add_options_page function is disallowed for the same reason, because themes should add their pages to the Appearance menu, not to the Settings menu.

  5. iLen
    Member
    Posted 1 month ago #

    Ok, no choice.
    Thanks for the prompt response.

Reply

You must log in to post.

About this Plugin

About this Topic

Tags

No tags yet.