Title: Undefined array key &#8220;menu_status&#8221;
Last modified: September 16, 2025

---

# Undefined array key “menu_status”

 *  [sko4a](https://wordpress.org/support/users/sko4a/)
 * (@sko4a)
 * [6 months, 3 weeks ago](https://wordpress.org/support/topic/undefined-array-key-menu_status/)
 * Hi, I’m experiencing the following error when saving posts with the plugin enabled:
 *     ```wp-block-code
       Warning: Undefined array key "menu_status" in /wp-content/plugins/floating-side-tab/includes/classes/admin/class-fsdt-metabox.php on line 88Warning: Cannot modify header information - headers already sent by (output started at /wp-content/plugins/floating-side-tab/includes/classes/admin/class-fsdt-metabox.php:88) in /wp-admin/post.php on line 231Warning: Cannot modify header information - headers already sent by (output started at /wp-content/plugins/floating-side-tab/includes/classes/admin/class-fsdt-metabox.php:88) in /wp-includes/pluggable.php on line 1450Warning: Cannot modify header information - headers already sent by (output started at /wp-content/plugins/floating-side-tab/includes/classes/admin/class-fsdt-metabox.php:88) in /wp-includes/pluggable.php on line 1453
       ```
   
 * I’ve fixed it with AI support, but maybe you would like to review and incorporate
   the fix in your stable version. Error explanation: The core issue is that the
   code attempts to access array keys (`menu_status` and `post_type_menu`) from 
   the `$_POST` array without first checking if those keys exist, which triggers
   the “Undefined array key” warning. This warning is then interpreted as output,
   causing the “headers already sent” error and preventing the post from being saved.
 * Here is the suggested improvement of the class-fsdt-metabox.php file:
 *     ```wp-block-code
       function fsdt_save_meta_box($post_id, $post){    // Check if the nonce field is present and valid    if (        !empty($_POST['fsdt_settings_post_nonce_field']) &&        wp_verify_nonce($_POST['fsdt_settings_post_nonce_field'], 'fsdt_settings_post_nonce')    ) {        // Initialize an empty array for meta details        $fsdt_meta_detail = array();        // Safely check and sanitize the menu_status key        if (isset($_POST['fsdt_meta_detail']['menu_status'])) {            $fsdt_meta_detail['menu_status'] = sanitize_text_field($_POST['fsdt_meta_detail']['menu_status']);        } else {            // Set a default value if the key is not present            $fsdt_meta_detail['menu_status'] = '';        }        // Safely check and sanitize the post_type_menu key        if (isset($_POST['fsdt_meta_detail']['post_type_menu'])) {            $fsdt_meta_detail['post_type_menu'] = sanitize_text_field($_POST['fsdt_meta_detail']['post_type_menu']);        } else {            // Set a default value if the key is not present            $fsdt_meta_detail['post_type_menu'] = 'Default';        }        // Update the post meta with the safely retrieved and sanitized data        update_post_meta($post_id, 'fsdt_meta_detail', $fsdt_meta_detail);    }}
       ```
   

Viewing 2 replies - 1 through 2 (of 2 total)

 *  Plugin Support [aacesc](https://wordpress.org/support/users/aacesc/)
 * (@aacesc)
 * [6 months, 3 weeks ago](https://wordpress.org/support/topic/undefined-array-key-menu_status/#post-18644595)
 * Hello [@sko4a](https://wordpress.org/support/users/sko4a/) 
   Thank you for notifying
   the issue regarding this. We are checking and get back to you shortly.Thanks.
 *  Plugin Support [aacesc](https://wordpress.org/support/users/aacesc/)
 * (@aacesc)
 * [6 months, 3 weeks ago](https://wordpress.org/support/topic/undefined-array-key-menu_status/#post-18646221)
 * Hello [@sko4a](https://wordpress.org/support/users/sko4a/) 
   Just to inform you,
   we have fixed the issue and already released an update today. Please update the
   plugin and let us know if the issue has been resolved or not.Thanks.

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘Undefined array key “menu_status”’ is closed to new replies.

 * ![](https://ps.w.org/floating-side-tab/assets/icon-256x256.png?rev=3053118)
 * [Floating Side Tab](https://wordpress.org/plugins/floating-side-tab/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/floating-side-tab/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/floating-side-tab/)
 * [Active Topics](https://wordpress.org/support/plugin/floating-side-tab/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/floating-side-tab/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/floating-side-tab/reviews/)

 * 2 replies
 * 2 participants
 * Last reply from: [aacesc](https://wordpress.org/support/users/aacesc/)
 * Last activity: [6 months, 3 weeks ago](https://wordpress.org/support/topic/undefined-array-key-menu_status/#post-18646221)
 * Status: not resolved