Claudia M Posted November 15, 2018 Share Posted November 15, 2018 Hi, I want to reorder the menu on the admin page - Customers, Inventory, Reporting, File Manager, etc and their sub categories. What file(s) do I edit? Thanks in advance for any and all help and responses. Claudia Link to comment Share on other sites More sharing options...
bsmither Posted November 15, 2018 Share Posted November 15, 2018 That would be the admin source file element.navigation.inc.php. Re-order the $nav_sections array to suit. (Pay close attention to the fact that the last element of these arrays do not have a trailing comma. So, if moving the last element to some place not the last, be sure to add a trailing comma.) There is also a hook at the bottom that can be used to re-assign the $nav_sections array, and by doing the hook thing, your order of elements will be preserved from an upgrade. Link to comment Share on other sites More sharing options...
Claudia M Posted November 15, 2018 Author Share Posted November 15, 2018 Thanks Brian, How would I do this? There is also a hook at the bottom that can be used to re-assign the $nav_sections array, and by doing the hook thing, your order of elements will be preserved from an upgrade. Link to comment Share on other sites More sharing options...
bsmither Posted November 15, 2018 Share Posted November 15, 2018 In admin, Manage Hooks, Code Snippets tab, click Add Snippet. The page will reload with a form below the existing snippet list. Enabled: checked Unique ID: admin_nav_order@cc600+ Execution Order: 1 Description: Admin Navigation Sections Custom Listing Order Trigger: admin.navigation Version: 1.0 Author: https://forums.cubecart.com/topic/54542-change-order-in-admin-menu/ PHP Code: <?php /********* * arrange the array elements in the order you want them to appear *********/ $nav_sections = array( 'customers' => $lang['navigation']['nav_customers'], 'inventory' => $lang['navigation']['nav_inventory'], 'reporting' => $lang['navigation']['nav_reporting'], 'filemanager' => $lang['navigation']['nav_file_manager'], 'settings' => $lang['navigation']['nav_settings'], 'modules' => $lang['navigation']['nav_modules'], 'advanced' => $lang['navigation']['nav_advanced'], ); Save and clear CubeCart's internal cache. This may interfere with the results of other snippets and plugins that want to add Nav Sections to admin. Link to comment Share on other sites More sharing options...
Claudia M Posted November 15, 2018 Author Share Posted November 15, 2018 Thanks so much for this Brian. Will implement it ASAP!!! Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.