Hello,

I wish to customise the navbar in a drupal 7 + bootstrap theme.

I cannot seem to find where this can be done. Does it have to be hard coded somewhere?

I would like to add a search bar, a banner and another row of links to the navbar.

I would like future users to be able to modify the banner image and links so I would rather not hardcode it.

Where and how can I do this?

alternatively, can the thing be completely disabled?

thank you

Comments

StuEee’s picture

They have plenty of resources directly at their website - getbootstrap.com
Personally though, bootstrap looks pretty, but is bloated.

drummondf’s picture

Firebug is your friend :) If you're using the CDN for this Firebug won't pick up the settings, you'll need to infer them from the page structure.

Yes, everything you're seeking to do can be done via CSS.

Ask me about marketing

gobnat’s picture

Yes, everything you're seeking to do can be done via CSS.

getting my hands dirty with bootstrap is fine, the problem is I need to make parts of it maintainable by people who do no have technical skills.

The site I am building is a Drupal implementation of a straight bootstrap prototype. I need to make it possible for others to modify components etc.

At the moment I can find no way to edit/modify the Navbar from within Drupal; This is somewhat unsatisfactory. Other parts of the site can be edited from within Drupal and I was just hoping there was a way to do this with the navbar. I am a little confused as to why they would hardcode it to be honest, surely people are going to want to modify it?

drummondf’s picture

What will need to be edited and what level of permission to you want to grant those with the ability to edit?

Ask me about marketing

gobnat’s picture

what will need to be edited and what level of permission to you want to grant those with the ability to edit?

At least:
Banner image
Menu links

editors will have admin level permissions.

thanks for any help btw :)

drummondf’s picture

The menu is not very intuitive here. Typically the menu would be set via the Blocks menu, where you would indiciate the Main Menu goes in the Navbar region. Bootstrap assumes this, so if you have ticked in the Appearance section "Main Menu" then it is automatically displaying in the Navbar.

You can edit that menu from the Menus section of Drupal, it will be the Main Menu.

When you say edit the banner image, do you mean change the background of the navbar, or add an additional banner somewhere? That sounds like a Block that should be placed in the Top Bar section.

Ask me about marketing

kruser’s picture

I agree, it's difficult to deal with the hardcoded navbar in bootstrap theme. The hard coding is in the page.tpl.php (bootstrap/system/page.tpl.php)

You could strip out the hard coding and replace with additional regions within the navbar.

-----------------------------------------------------
Bob @ Drupal Aid (https://www.drupalaid.com)

MLZR’s picture

Maybe for someone a nice and very easy work-arround for the menu problem(s):

The menu in this theme is in 1 place, and I can't do much with it. So I installed an other module for the menu. In my case TB-Megamenu.

This mudule works fine, lots of flexibility and it are BLOCKS, so you can put is anywhere you want.

But then the 'baked - in' menu? I just see in the code ( in page.tpl.php ) that when there are no links in the default main menu, it just skips the display of that menu at all.

SO.. I dropped/delete all the links in de default main menu and create a new custom menu ( admin/structure/menu/add ) and... violá.. the original menu is gone...AND I have a new menu block with endless possibility’s AND TB- megamenu play's top with Bootstrap even to the small screens... bud I guess with other menu-systems it will work also.

Just don't use the standard main menu...

MLZR’s picture

Just saw the settings for the menu, this is an even better and quicker work- around to get the original menu disappeared...:

on admin/structure/menu/settings (it's admin/structure/menu , then TAB settings), there you can chose witch of the menu's is the main menu... and the theme is going to render it. And that’s what we don't want.

So to get the standard menu in the theme to disappear, just chose with "Source for the Main links" 'no main links' and save.
Now the theme get's no content/links to render as 'main menu' and the standard menu in the theme will disappear.

This is an even more easy way to get the standard menu go away... AND still use the 'Main menu' .. of all things

UnsettlingTrend’s picture

Why wouldn't you just go to the theme's settings and turn off the Main Menu?

admin/appearance/settings/themename -> uncheck "Main Menu" from "Toggle Display"