WordPress.org

Forums

[resolved] Tabbed navigation for plugin options using same row in database for all? (3 posts)

  1. Christiaan Conover
    Member
    Posted 11 months ago #

    I'm trying to use WordPress' native tabbed navigation on my plugin's options page, but I'm having trouble. I've managed to get the options to display, though it displays every plugin option on every tab. I also get the error message ERROR: options page not found whenever I try to save settings.

    I think I've traced this to the fact that I'm trying to use the same row in the database for all plugin options. The reason for this is that most of the options fields are dynamically generated from a remote API call, so the tabs may not be the same across all installations of the plugin. Therefore, I don't want to predefine database rows for each tab, in case certain tabs are not in use, or tabs are added or removed based on the API response after plugin installation.

    Is it possible to use a single row in the database for all plugin options in conjunction with WordPress' tabbed navigation?

    Here's the relevant block of code in the commit containing it. I've linked to it because it contains references to methods and properties elsewhere in plugin code that may be relevant for context.

  2. esmi
    Forum Moderator
    Posted 11 months ago #

  3. Christiaan Conover
    Member
    Posted 10 months ago #

    Thanks, it looks like I can't quite do what I'm trying to do, so I'll try another tactic.

Reply

You must log in to post.

About this Topic