WordPress.org

Ready to get started?Download WordPress

Forums

Multiple Metabox Save Options (1 post)

  1. In my plugin, I have five metaboxes with different option sets. I'm trying to wrap each metabox option set in a form, which when updated, does not interfere with the other option sets.

    (ALL options are saved as single array in wp_options table)

    Here are two basic functions (each one used in it's own metabox):

    function jwl_buttons_group_1($data) {
       <form action="options.php" method="post" name="jwl_main_options1">
       <?php
       do_settings_sections('ultimate-tinymce1');
       settings_fields('jwl_options_group');
       ?>
       </form>
    }
    function jwl_buttons_group_2($data) {
       <form action="options.php" method="post" name="jwl_main_options2">
       <?php
       do_settings_sections('ultimate-tinymce2');
       settings_fields('jwl_options_group');
       ?>
       </form>
    }

    The problem is when I update buttons group one, it wipes out buttons group two's options (if any were set).

    Any ideas?

Topic Closed

This topic has been closed to new replies.

About this Topic

  • RSS feed for this topic
  • Started 2 years ago by Josh (WP Edit)
  • This topic is not resolved
  • WordPress version: 3.4.1

Tags

No tags yet.