=== CC Duplicate Menu === Contributors: caterhamcomputing Donate link: https://ccplugins.co.uk/donate/ Tags: menu, navigation, duplicate, clone, admin Requires at least: 6.4 Tested up to: 6.9 Requires PHP: 7.4 Stable tag: 1.0.0 License: GPLv2 or later License URI: https://www.gnu.org/licenses/gpl-2.0.html Safely duplicate WordPress navigation menus from the menu editor. == Description == CC Duplicate Menu adds a Duplicate Menu button to the WordPress menu editor, allowing you to create a full copy of an existing navigation menu. The duplicated menu: * uses the original menu name with “ (copy)” appended * keeps the same links and labels * preserves menu hierarchy and order * creates new menu items so the copied menu can be edited independently The plugin is built with security, privacy and WordPress coding standards in mind. == Installation == 1. Upload the plugin files to the `/wp-content/plugins/cc-duplicate-menu/` directory, or install the plugin through the WordPress plugins screen. 2. Activate the plugin through the ‘Plugins’ screen in WordPress. 3. Go to Appearance → Menus. 4. Edit an existing menu and use the Duplicate Menu button between Save Menu and Delete Menu. == Frequently Asked Questions == = Does this alter my original menu? = No. A new menu is created with new menu items, so the copied menu can be edited independently. = Does it preserve nested menu items? = Yes. The duplicated menu preserves hierarchy and order. = Does it duplicate custom menu item metadata too? = Yes. This version safely copies standard WordPress menu item fields and non-core menu item metadata, while excluding protected internal keys. Filters are included for developers and future extensions that need more control. == Screenshots == 1. Duplicate Menu button shown between the Save Menu and Delete Menu controls. 2. Success notice after duplicating a menu. 3. Newly duplicated menu opened in the editor. == Changelog == = 1.0.0 = * Finalised release candidate for first public repository release. * Improved button placement to sit naturally between Save Menu and Delete Menu. * Refined redirect, notice and duplication flow for a smoother editing experience. * Added WordPress.org icon assets and final release packaging polish. = 0.3.0 = * Fixed menu detection on sites where the current menu ID is present in the edit form but not in the URL. * Made button insertion more robust by reading the current menu ID from the core hidden field when needed. * Added retry logic so the button is inserted reliably if the menu editor markup finishes rendering after the script loads. * Improved button placement in the footer publishing actions area and added a busy state while duplication is submitted. = 0.2.1 = * Fixed Duplicate Menu button insertion on current WordPress menu editor markup. = 0.2.0 = * Added safe copying of non-core menu item metadata by default. * Added filters to skip meta keys or adjust copied meta values. * Expanded protected meta key handling for better compatibility with advanced menu plugins. * Improved duplication robustness for plugin-enhanced menus. = 0.1.1 = * Refined initial repository-ready release. * Added secure duplicate action handling, notices and redirect behaviour. * Added extension hooks and filters for future premium functionality. * Improved internal structure, sanitization and coding standards alignment. = 0.1.0 = * Initial development version.