navbar

Can't Toggle Navbar in Bootstrap 4 in Angular

会有一股神秘感。 提交于 2019-12-04 08:11:15
问题 Why i can't toggle navbar when resizing to mobile screen in angular 4 using bootstrap 4. I included it in the angular cli in script and styles, the node modules from bootstrap. Is there something missing in my code? Please check below. Is there something wrong? Please help <nav class="navbar navbar-expand-md navbar-dark fixed-top bg-dark"> <a class="navbar-brand" href="#">Dashboard</a> <button class="navbar-toggler d-lg-none" type="button" data-toggle="collapse" data-target="

Float one navbar item right Bootstrap4 and keep centered links

落爺英雄遲暮 提交于 2019-12-04 06:57:47
问题 I'm trying to float the "login with discord" text and image to the right while the other 2 navbar links stay in the center. Whenever I tried to float it right the centered content/nav items got pushed over to the left about the width of the "login with discord" button. I'm trying to float it right without the center content moving. Here's my code. <body class="text-center"> <div class="cover-container d-flex h-100 p-3 mx-auto flex-column"> <header class="masthead mb-auto mr-auto ml-auto">

How do I center a navbar-brand [duplicate]

泄露秘密 提交于 2019-12-04 06:56:11
问题 This question already has answers here : Center an element in Bootstrap 4 Navbar (9 answers) Bootstrap NavBar with left, center or right aligned items (9 answers) Bootstrap 4 center navbar brand with collapse (4 answers) Closed 15 days ago . I've tried a few things like using flex boxes auto margins and transforms etc but I can't seem to center this navbar-brand because it centers between the right hand side and a button and I want it to ignore the button and just center for the whole of the

Django: how to get the name of the template being rendered

半腔热情 提交于 2019-12-04 05:06:48
I'm implementing a bootstrap navbar as show in this example here Items in a navbar are <li>'s , the "selected" item has the attribute class="active" : <li class="active"> <a href="#"> Link1 </a> </li> <li> <a href="#"> Link2 </a> </li> In Django these items will be within a template, which gets included by any templates that are supposed to display the navbar. I'm thinking about doing it this way: <li> <a href="/" class="{% if template_name == "home.djhtml" %}active{% endif %}"> Home </a> </li> <li> <a href="about/" class="{% if template_name == "about.djhtml" %}active{% endif %}"> About </a>

Navbar dropdown not working on mobile devices

时间秒杀一切 提交于 2019-12-04 05:01:41
I've run into an issue with the navbar in Bootstrap 3. One of my menu items is a dropdown, which works fine on my laptop, but doesn't work on my android phone. Specifically nothing happens when pressing on the dropdown menu item on my phone. I've searched google, this site, and several others for a solution, but have yet to find one. There seems to be a few solutions/workarounds for Bootstrap 2, but none of them seem to work for me. I know there are some differences between version 2 and 3, which may be why none of the solutions I tried worked. Any suggestions or references I can look at would

Bootstrap Navbar overtop Carousel

坚强是说给别人听的谎言 提交于 2019-12-04 04:55:59
Having a slight problem with the positioning of my navbar. I have my navbar the way I would like (detached from the top slightly like in this example: http://getbootstrap.com/examples/carousel/ ) but the pictures in my carousel end below the navbar. I would like for the pictures in my carousel to extend all the way to the top of the page and have the navbar overlapping the upper portion of the carousel (like in the example above). I've played around with the padding but the highest I can get the carousel images to extend to are the bottom of the navbar. I've attached the code snippets for the

How to centre navbar logo in Boostrap 4 with nav-links below

*爱你&永不变心* 提交于 2019-12-04 02:27:27
问题 I can't seem to get the navbar logo to centre align with the nav-links centre below it. I'm sure I'm missing something simple, I've checked out a few other posts regarding this issue but all seem to be using older versions of bootstrap. I am currently using bootstrap 4.0. Specifically, I want the logo on its own separate row, not on the same one as the links. <nav class="navbar navbar-expand-lg navbar-light bg-light"> <a class="navbar-brand" href="#"><img src="img/h-tech-logo-cropped.png"/><

Bootstrap - navbar-fixed-top covers content

ぐ巨炮叔叔 提交于 2019-12-04 02:20:20
I have a question about navbar-fixed-top. Well, I have a simple problem with it. My fixed navbar covers content, for example in "About us" page, it covers row with "About us" title. I have no idea how can I fix it, because when I resize website (mobile devices size) the header is visible. Of course I have this kind of problem with headers in other pages (Full Width and 404). Also, in Index page, it covers some of carousel slider. Information: website: http://testerix.site90.com/index.html bootstrap 2.3.2 Let me know, how can I fix it on all resolutions. Pablote the response is in the page:

Bootstrap 4 Navbar doesnt collapse in Angular4

北城余情 提交于 2019-12-04 02:13:22
问题 I'm working with Bootstrap 4 and Ng-Bootstrap in an Angular 4 Project, i have linked the que bootstrap.css in my angular-cli.json this way "styles": [ "../node_modules/bootstrap/dist/css/bootstrap.css", "styles.css" ], and imported the NgbModule in my app.module that looks like this import { BrowserModule } from '@angular/platform-browser'; import { NgModule } from '@angular/core'; import { NgbModule } from '@ng-bootstrap/ng-bootstrap'; import { AppComponent } from './app.component';

Multiple Collapse buttons in navbar with Bootstrap 3.0

丶灬走出姿态 提交于 2019-12-03 23:39:14
I'm using Bootstrap 3.0 to show a navbar with some links and a search field. When i go to "mobile version" i have a button that collapses the navbar and show all the content: the links and the search field. Now I need two buttons, one to collapse only the links of the navbar and the other button to collapse only the search field. How can i make this? Separate the links and the search form into two navbar-collapse elements and have each button target the corresponding one: Sample markup: <nav class="navbar navbar-default" role="navigation"> <div class="navbar-header"> <button type="button"