Support » Plugin: CMB2 » Best way to add form to existing admin page?

  • jeremycaris

    (@jeremycaris)


    I have already built a plugin with an admin page. I would like to update it to use a cmb2 form.

    When creating the box, I have to define the ‘object_types’, which may be “An array containing post type slugs, or ‘user’, ‘term’, ‘comment’, or ‘options-page’.”

    But I don’t want to create a new options page, and I don’t want the form to show on posts, pages, users, terms, or comments. What’s the best approach to take here?

    Thanks in advance!

Viewing 1 replies (of 1 total)
  • Plugin Author Michael Beckwith

    (@tw2113)

    The BenchPresser

    I suppose you could try to re-use the steps and ideas outlined in various places over at https://github.com/CMB2/CMB2/wiki for a frontend form, but personally I’d end up preferring to just let CMB2 handle an options page itself. I realize you have one already, but the library here isn’t really a general form builder. It’s meant to handle all the rest of the process of saving etc as well.

Viewing 1 replies (of 1 total)
  • You must be logged in to reply to this topic.