Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Hello,
I noticed the primary and secondary navigation is hardcoded. Could these be removed? Also, I Would love to simply add an FB Connect block on the right with the secondary menu without extra css :)
Please note hardwiring is being removed from D8 as well #1869476: Convert global menus (primary links, secondary links) into blocks
Comments
Comment #0.0
giorgio79 CreditAttribution: giorgio79 commented--double post, sorry --
Comment #0.1
giorgio79 CreditAttribution: giorgio79 commented--double post, sorry --
Comment #1
giorgio79 CreditAttribution: giorgio79 commentedI would be happy to attempt a patch, but would be good if a maintainer agrees with this issue :)
Comment #2
giorgio79 CreditAttribution: giorgio79 commented--double post, sorry -- sg wrong with Drupal today? :)
Comment #3
samwilson CreditAttribution: samwilson commentedI'd be interested in this feature too; has there been any progress on it?
Comment #4
markhalliwellI'm not sure what you want to see happen here. Themes cannot create blocks. The primary (main) and secondary menus are hardcoded in 7.x core. They can be changed via /admin/structure/menu/settings and the theme can toggle these menus in /admin/appearance/settings/bootstrap.
If you want something else in the navigation region, you can toggle off the menus and then place whatever block you want. How is that "hardcoded" and what exactly are you proposing to do differently?
Comment #5
samwilson CreditAttribution: samwilson commentedSorry, I should've clarified what I think is being requested here.
I think the 'hardcoding' part is that the primary and secondary menus are the only things that can be put into the navbar. A more free approach would be to make the navbar a region (or perhaps two, left and right) into which any blocks could be put. For example, a search block, or some non-menu information block. That would also mean they could be reordered, and one could have more than two menus in the navbar.
Although perhaps you're right: can all this be done by just disabling the primary and secondary menus and putting whatever blocks one wants in the header region? Hm... seems not; I just tried and they just end up under the navbar. Am I doing it wrong?
Thanks for helping with this! :)
Comment #6
markhalliwellI'm not sure... did you override page.tpl.php? By default the navigation region is rendered inside the navbar.
Comment #7
markhalliwell